mx_rs/lib.rs
1#[allow(unused_imports)]
2use progenitor_client::{encode_path, ClientHooks, OperationInfo, RequestBuilderExt};
3#[allow(unused_imports)]
4pub use progenitor_client::{ByteStream, ClientInfo, Error, ResponseValue};
5/// Types used as operation parameters and responses.
6#[allow(clippy::all)]
7pub mod types {
8 /// Error types.
9 pub mod error {
10 /// Error from a `TryFrom` or `FromStr` implementation.
11 pub struct ConversionError(::std::borrow::Cow<'static, str>);
12 impl ::std::error::Error for ConversionError {}
13 impl ::std::fmt::Display for ConversionError {
14 fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> Result<(), ::std::fmt::Error> {
15 ::std::fmt::Display::fmt(&self.0, f)
16 }
17 }
18
19 impl ::std::fmt::Debug for ConversionError {
20 fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> Result<(), ::std::fmt::Error> {
21 ::std::fmt::Debug::fmt(&self.0, f)
22 }
23 }
24
25 impl From<&'static str> for ConversionError {
26 fn from(value: &'static str) -> Self {
27 Self(value.into())
28 }
29 }
30
31 impl From<String> for ConversionError {
32 fn from(value: String) -> Self {
33 Self(value.into())
34 }
35 }
36 }
37
38 ///`AccountCreateRequest`
39 ///
40 /// <details><summary>JSON schema</summary>
41 ///
42 /// ```json
43 ///{
44 /// "type": "object",
45 /// "required": [
46 /// "account_type",
47 /// "name"
48 /// ],
49 /// "properties": {
50 /// "account_subtype": {
51 /// "examples": [
52 /// "PERSONAL"
53 /// ],
54 /// "type": "string"
55 /// },
56 /// "account_type": {
57 /// "examples": [
58 /// "SAVINGS"
59 /// ],
60 /// "type": "string"
61 /// },
62 /// "apr": {
63 /// "examples": [
64 /// 1
65 /// ],
66 /// "type": "number"
67 /// },
68 /// "apy": {
69 /// "examples": [
70 /// 1
71 /// ],
72 /// "type": "number"
73 /// },
74 /// "available_balance": {
75 /// "examples": [
76 /// 1000
77 /// ],
78 /// "type": "number"
79 /// },
80 /// "balance": {
81 /// "examples": [
82 /// 1000
83 /// ],
84 /// "type": "number"
85 /// },
86 /// "cash_surrender_value": {
87 /// "examples": [
88 /// 1000
89 /// ],
90 /// "type": "number"
91 /// },
92 /// "credit_limit": {
93 /// "examples": [
94 /// 100
95 /// ],
96 /// "type": "number"
97 /// },
98 /// "currency_code": {
99 /// "examples": [
100 /// "USD"
101 /// ],
102 /// "type": "string"
103 /// },
104 /// "death_benefit": {
105 /// "examples": [
106 /// 1000
107 /// ],
108 /// "type": "integer"
109 /// },
110 /// "interest_rate": {
111 /// "examples": [
112 /// 1
113 /// ],
114 /// "type": "number"
115 /// },
116 /// "is_business": {
117 /// "examples": [
118 /// false
119 /// ],
120 /// "type": "boolean"
121 /// },
122 /// "is_closed": {
123 /// "examples": [
124 /// false
125 /// ],
126 /// "type": "boolean"
127 /// },
128 /// "is_hidden": {
129 /// "examples": [
130 /// false
131 /// ],
132 /// "type": "boolean"
133 /// },
134 /// "loan_amount": {
135 /// "examples": [
136 /// 1000
137 /// ],
138 /// "type": "number"
139 /// },
140 /// "metadata": {
141 /// "examples": [
142 /// "some metadata"
143 /// ],
144 /// "type": "string"
145 /// },
146 /// "name": {
147 /// "examples": [
148 /// "Test account 2"
149 /// ],
150 /// "type": "string"
151 /// },
152 /// "nickname": {
153 /// "examples": [
154 /// "Swiss Account"
155 /// ],
156 /// "type": "string"
157 /// },
158 /// "original_balance": {
159 /// "examples": [
160 /// 10
161 /// ],
162 /// "type": "number"
163 /// },
164 /// "property_type": {
165 /// "examples": [
166 /// "VEHICLE"
167 /// ],
168 /// "type": "string"
169 /// },
170 /// "skip_webhook": {
171 /// "examples": [
172 /// true
173 /// ],
174 /// "type": "boolean"
175 /// }
176 /// }
177 ///}
178 /// ```
179 /// </details>
180 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
181 pub struct AccountCreateRequest {
182 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
183 pub account_subtype: ::std::option::Option<::std::string::String>,
184 pub account_type: ::std::string::String,
185 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
186 pub apr: ::std::option::Option<f64>,
187 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
188 pub apy: ::std::option::Option<f64>,
189 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
190 pub available_balance: ::std::option::Option<f64>,
191 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
192 pub balance: ::std::option::Option<f64>,
193 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
194 pub cash_surrender_value: ::std::option::Option<f64>,
195 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
196 pub credit_limit: ::std::option::Option<f64>,
197 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
198 pub currency_code: ::std::option::Option<::std::string::String>,
199 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
200 pub death_benefit: ::std::option::Option<i64>,
201 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
202 pub interest_rate: ::std::option::Option<f64>,
203 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
204 pub is_business: ::std::option::Option<bool>,
205 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
206 pub is_closed: ::std::option::Option<bool>,
207 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
208 pub is_hidden: ::std::option::Option<bool>,
209 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
210 pub loan_amount: ::std::option::Option<f64>,
211 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
212 pub metadata: ::std::option::Option<::std::string::String>,
213 pub name: ::std::string::String,
214 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
215 pub nickname: ::std::option::Option<::std::string::String>,
216 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
217 pub original_balance: ::std::option::Option<f64>,
218 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
219 pub property_type: ::std::option::Option<::std::string::String>,
220 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
221 pub skip_webhook: ::std::option::Option<bool>,
222 }
223
224 impl ::std::convert::From<&AccountCreateRequest> for AccountCreateRequest {
225 fn from(value: &AccountCreateRequest) -> Self {
226 value.clone()
227 }
228 }
229
230 ///`AccountCreateRequestBody`
231 ///
232 /// <details><summary>JSON schema</summary>
233 ///
234 /// ```json
235 ///{
236 /// "type": "object",
237 /// "properties": {
238 /// "account": {
239 /// "$ref": "#/components/schemas/AccountCreateRequest"
240 /// }
241 /// }
242 ///}
243 /// ```
244 /// </details>
245 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
246 pub struct AccountCreateRequestBody {
247 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
248 pub account: ::std::option::Option<AccountCreateRequest>,
249 }
250
251 impl ::std::convert::From<&AccountCreateRequestBody> for AccountCreateRequestBody {
252 fn from(value: &AccountCreateRequestBody) -> Self {
253 value.clone()
254 }
255 }
256
257 impl ::std::default::Default for AccountCreateRequestBody {
258 fn default() -> Self {
259 Self {
260 account: Default::default(),
261 }
262 }
263 }
264
265 ///`AccountNumberResponse`
266 ///
267 /// <details><summary>JSON schema</summary>
268 ///
269 /// ```json
270 ///{
271 /// "type": "object",
272 /// "properties": {
273 /// "account_guid": {
274 /// "examples": [
275 /// "ACT-06d7f45b-caae-0f6e-1384-01f52e75dcb1"
276 /// ],
277 /// "type": [
278 /// "string",
279 /// "null"
280 /// ]
281 /// },
282 /// "account_number": {
283 /// "examples": [
284 /// "10001"
285 /// ],
286 /// "type": [
287 /// "string",
288 /// "null"
289 /// ]
290 /// },
291 /// "guid": {
292 /// "examples": [
293 /// "ACN-8899832e-e5b4-42cd-aa25-bbf1dc889a8f"
294 /// ],
295 /// "type": [
296 /// "string",
297 /// "null"
298 /// ]
299 /// },
300 /// "institution_number": {
301 /// "examples": [
302 /// "123"
303 /// ],
304 /// "type": [
305 /// "string",
306 /// "null"
307 /// ]
308 /// },
309 /// "loan_guarantor": {
310 /// "examples": [
311 /// "U.S. DEPARTMENT OF EDUCATION (123456)"
312 /// ],
313 /// "type": [
314 /// "string",
315 /// "null"
316 /// ]
317 /// },
318 /// "loan_reference_number": {
319 /// "examples": [
320 /// "123456789012345"
321 /// ],
322 /// "type": [
323 /// "string",
324 /// "null"
325 /// ]
326 /// },
327 /// "member_guid": {
328 /// "examples": [
329 /// "MBR-7c6f361b-e582-15b6-60c0-358f12466b4b"
330 /// ],
331 /// "type": [
332 /// "string",
333 /// "null"
334 /// ]
335 /// },
336 /// "passed_validation": {
337 /// "examples": [
338 /// true
339 /// ],
340 /// "type": [
341 /// "boolean",
342 /// "null"
343 /// ]
344 /// },
345 /// "routing_number": {
346 /// "examples": [
347 /// "68899990000000"
348 /// ],
349 /// "type": [
350 /// "string",
351 /// "null"
352 /// ]
353 /// },
354 /// "sequence_number": {
355 /// "examples": [
356 /// "1-01"
357 /// ],
358 /// "type": [
359 /// "string",
360 /// "null"
361 /// ]
362 /// },
363 /// "transit_number": {
364 /// "examples": [
365 /// "12345"
366 /// ],
367 /// "type": [
368 /// "string",
369 /// "null"
370 /// ]
371 /// },
372 /// "user_guid": {
373 /// "examples": [
374 /// "USR-fa7537f3-48aa-a683-a02a-b18940482f54"
375 /// ],
376 /// "type": [
377 /// "string",
378 /// "null"
379 /// ]
380 /// }
381 /// }
382 ///}
383 /// ```
384 /// </details>
385 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
386 pub struct AccountNumberResponse {
387 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
388 pub account_guid: ::std::option::Option<::std::string::String>,
389 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
390 pub account_number: ::std::option::Option<::std::string::String>,
391 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
392 pub guid: ::std::option::Option<::std::string::String>,
393 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
394 pub institution_number: ::std::option::Option<::std::string::String>,
395 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
396 pub loan_guarantor: ::std::option::Option<::std::string::String>,
397 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
398 pub loan_reference_number: ::std::option::Option<::std::string::String>,
399 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
400 pub member_guid: ::std::option::Option<::std::string::String>,
401 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
402 pub passed_validation: ::std::option::Option<bool>,
403 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
404 pub routing_number: ::std::option::Option<::std::string::String>,
405 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
406 pub sequence_number: ::std::option::Option<::std::string::String>,
407 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
408 pub transit_number: ::std::option::Option<::std::string::String>,
409 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
410 pub user_guid: ::std::option::Option<::std::string::String>,
411 }
412
413 impl ::std::convert::From<&AccountNumberResponse> for AccountNumberResponse {
414 fn from(value: &AccountNumberResponse) -> Self {
415 value.clone()
416 }
417 }
418
419 impl ::std::default::Default for AccountNumberResponse {
420 fn default() -> Self {
421 Self {
422 account_guid: Default::default(),
423 account_number: Default::default(),
424 guid: Default::default(),
425 institution_number: Default::default(),
426 loan_guarantor: Default::default(),
427 loan_reference_number: Default::default(),
428 member_guid: Default::default(),
429 passed_validation: Default::default(),
430 routing_number: Default::default(),
431 sequence_number: Default::default(),
432 transit_number: Default::default(),
433 user_guid: Default::default(),
434 }
435 }
436 }
437
438 ///`AccountNumbersResponseBody`
439 ///
440 /// <details><summary>JSON schema</summary>
441 ///
442 /// ```json
443 ///{
444 /// "type": "object",
445 /// "properties": {
446 /// "account_numbers": {
447 /// "type": "array",
448 /// "items": {
449 /// "$ref": "#/components/schemas/AccountNumberResponse"
450 /// }
451 /// },
452 /// "pagination": {
453 /// "$ref": "#/components/schemas/PaginationResponse"
454 /// }
455 /// }
456 ///}
457 /// ```
458 /// </details>
459 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
460 pub struct AccountNumbersResponseBody {
461 #[serde(default, skip_serializing_if = "::std::vec::Vec::is_empty")]
462 pub account_numbers: ::std::vec::Vec<AccountNumberResponse>,
463 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
464 pub pagination: ::std::option::Option<PaginationResponse>,
465 }
466
467 impl ::std::convert::From<&AccountNumbersResponseBody> for AccountNumbersResponseBody {
468 fn from(value: &AccountNumbersResponseBody) -> Self {
469 value.clone()
470 }
471 }
472
473 impl ::std::default::Default for AccountNumbersResponseBody {
474 fn default() -> Self {
475 Self {
476 account_numbers: Default::default(),
477 pagination: Default::default(),
478 }
479 }
480 }
481
482 ///`AccountOwnerResponse`
483 ///
484 /// <details><summary>JSON schema</summary>
485 ///
486 /// ```json
487 ///{
488 /// "type": "object",
489 /// "properties": {
490 /// "account_guid": {
491 /// "examples": [
492 /// "ACT-06d7f44b-caae-0f6e-1384-01f52e75dcb1"
493 /// ],
494 /// "type": [
495 /// "string",
496 /// "null"
497 /// ]
498 /// },
499 /// "address": {
500 /// "examples": [
501 /// "123 This Way"
502 /// ],
503 /// "type": [
504 /// "string",
505 /// "null"
506 /// ]
507 /// },
508 /// "city": {
509 /// "examples": [
510 /// "Middlesex"
511 /// ],
512 /// "type": [
513 /// "string",
514 /// "null"
515 /// ]
516 /// },
517 /// "country": {
518 /// "examples": [
519 /// "US"
520 /// ],
521 /// "type": [
522 /// "string",
523 /// "null"
524 /// ]
525 /// },
526 /// "email": {
527 /// "examples": [
528 /// "donnie@darko.co"
529 /// ],
530 /// "type": [
531 /// "string",
532 /// "null"
533 /// ]
534 /// },
535 /// "first_name": {
536 /// "examples": [
537 /// "Donnie"
538 /// ],
539 /// "type": [
540 /// "string",
541 /// "null"
542 /// ]
543 /// },
544 /// "guid": {
545 /// "examples": [
546 /// "ACO-63dc7714-6fc0-4aa2-a069-c06cdccd1af9"
547 /// ],
548 /// "type": [
549 /// "string",
550 /// "null"
551 /// ]
552 /// },
553 /// "last_name": {
554 /// "examples": [
555 /// "Darko"
556 /// ],
557 /// "type": [
558 /// "string",
559 /// "null"
560 /// ]
561 /// },
562 /// "member_guid": {
563 /// "examples": [
564 /// "MBR-7c6f361b-e582-15b6-60c0-358f12466b4b"
565 /// ],
566 /// "type": [
567 /// "string",
568 /// "null"
569 /// ]
570 /// },
571 /// "owner_name": {
572 /// "examples": [
573 /// "Donnie Darko"
574 /// ],
575 /// "type": [
576 /// "string",
577 /// "null"
578 /// ]
579 /// },
580 /// "phone": {
581 /// "examples": [
582 /// "555-555-5555"
583 /// ],
584 /// "type": [
585 /// "string",
586 /// "null"
587 /// ]
588 /// },
589 /// "postal_code": {
590 /// "examples": [
591 /// "00000-0000"
592 /// ],
593 /// "type": [
594 /// "string",
595 /// "null"
596 /// ]
597 /// },
598 /// "state": {
599 /// "examples": [
600 /// "VA"
601 /// ],
602 /// "type": [
603 /// "string",
604 /// "null"
605 /// ]
606 /// },
607 /// "user_guid": {
608 /// "examples": [
609 /// "USR-fa7537f3-48aa-a683-a02a-b18940482f54"
610 /// ],
611 /// "type": [
612 /// "string",
613 /// "null"
614 /// ]
615 /// }
616 /// }
617 ///}
618 /// ```
619 /// </details>
620 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
621 pub struct AccountOwnerResponse {
622 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
623 pub account_guid: ::std::option::Option<::std::string::String>,
624 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
625 pub address: ::std::option::Option<::std::string::String>,
626 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
627 pub city: ::std::option::Option<::std::string::String>,
628 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
629 pub country: ::std::option::Option<::std::string::String>,
630 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
631 pub email: ::std::option::Option<::std::string::String>,
632 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
633 pub first_name: ::std::option::Option<::std::string::String>,
634 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
635 pub guid: ::std::option::Option<::std::string::String>,
636 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
637 pub last_name: ::std::option::Option<::std::string::String>,
638 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
639 pub member_guid: ::std::option::Option<::std::string::String>,
640 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
641 pub owner_name: ::std::option::Option<::std::string::String>,
642 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
643 pub phone: ::std::option::Option<::std::string::String>,
644 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
645 pub postal_code: ::std::option::Option<::std::string::String>,
646 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
647 pub state: ::std::option::Option<::std::string::String>,
648 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
649 pub user_guid: ::std::option::Option<::std::string::String>,
650 }
651
652 impl ::std::convert::From<&AccountOwnerResponse> for AccountOwnerResponse {
653 fn from(value: &AccountOwnerResponse) -> Self {
654 value.clone()
655 }
656 }
657
658 impl ::std::default::Default for AccountOwnerResponse {
659 fn default() -> Self {
660 Self {
661 account_guid: Default::default(),
662 address: Default::default(),
663 city: Default::default(),
664 country: Default::default(),
665 email: Default::default(),
666 first_name: Default::default(),
667 guid: Default::default(),
668 last_name: Default::default(),
669 member_guid: Default::default(),
670 owner_name: Default::default(),
671 phone: Default::default(),
672 postal_code: Default::default(),
673 state: Default::default(),
674 user_guid: Default::default(),
675 }
676 }
677 }
678
679 ///`AccountOwnersResponseBody`
680 ///
681 /// <details><summary>JSON schema</summary>
682 ///
683 /// ```json
684 ///{
685 /// "type": "object",
686 /// "properties": {
687 /// "account_owners": {
688 /// "type": "array",
689 /// "items": {
690 /// "$ref": "#/components/schemas/AccountOwnerResponse"
691 /// }
692 /// },
693 /// "pagination": {
694 /// "$ref": "#/components/schemas/PaginationResponse"
695 /// }
696 /// }
697 ///}
698 /// ```
699 /// </details>
700 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
701 pub struct AccountOwnersResponseBody {
702 #[serde(default, skip_serializing_if = "::std::vec::Vec::is_empty")]
703 pub account_owners: ::std::vec::Vec<AccountOwnerResponse>,
704 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
705 pub pagination: ::std::option::Option<PaginationResponse>,
706 }
707
708 impl ::std::convert::From<&AccountOwnersResponseBody> for AccountOwnersResponseBody {
709 fn from(value: &AccountOwnersResponseBody) -> Self {
710 value.clone()
711 }
712 }
713
714 impl ::std::default::Default for AccountOwnersResponseBody {
715 fn default() -> Self {
716 Self {
717 account_owners: Default::default(),
718 pagination: Default::default(),
719 }
720 }
721 }
722
723 ///`AccountResponse`
724 ///
725 /// <details><summary>JSON schema</summary>
726 ///
727 /// ```json
728 ///{
729 /// "type": "object",
730 /// "properties": {
731 /// "account_number": {
732 /// "examples": [
733 /// "5366"
734 /// ],
735 /// "type": [
736 /// "string",
737 /// "null"
738 /// ]
739 /// },
740 /// "account_number_set_by": {
741 /// "examples": [
742 /// 1
743 /// ],
744 /// "type": [
745 /// "integer",
746 /// "null"
747 /// ]
748 /// },
749 /// "account_ownership": {
750 /// "examples": [
751 /// "INDIVIDUAL"
752 /// ],
753 /// "type": [
754 /// "string",
755 /// "null"
756 /// ]
757 /// },
758 /// "annuity_policy_to_date": {
759 /// "examples": [
760 /// "2016-10-13T17:57:37.000Z"
761 /// ],
762 /// "type": [
763 /// "string",
764 /// "null"
765 /// ]
766 /// },
767 /// "annuity_provider": {
768 /// "examples": [
769 /// "Metlife"
770 /// ],
771 /// "type": [
772 /// "string",
773 /// "null"
774 /// ]
775 /// },
776 /// "annuity_term_year": {
777 /// "examples": [
778 /// 2048
779 /// ],
780 /// "type": [
781 /// "integer",
782 /// "null"
783 /// ]
784 /// },
785 /// "apr": {
786 /// "examples": [
787 /// 1
788 /// ],
789 /// "type": [
790 /// "number",
791 /// "null"
792 /// ]
793 /// },
794 /// "apr_set_by": {
795 /// "examples": [
796 /// 1
797 /// ],
798 /// "type": [
799 /// "integer",
800 /// "null"
801 /// ]
802 /// },
803 /// "apy": {
804 /// "examples": [
805 /// 1
806 /// ],
807 /// "type": [
808 /// "number",
809 /// "null"
810 /// ]
811 /// },
812 /// "apy_set_by": {
813 /// "examples": [
814 /// 1
815 /// ],
816 /// "type": [
817 /// "integer",
818 /// "null"
819 /// ]
820 /// },
821 /// "available_balance": {
822 /// "examples": [
823 /// 1000
824 /// ],
825 /// "type": [
826 /// "number",
827 /// "null"
828 /// ]
829 /// },
830 /// "available_balance_set_by": {
831 /// "examples": [
832 /// 1
833 /// ],
834 /// "type": [
835 /// "integer",
836 /// "null"
837 /// ]
838 /// },
839 /// "available_credit": {
840 /// "examples": [
841 /// 1000
842 /// ],
843 /// "type": [
844 /// "number",
845 /// "null"
846 /// ]
847 /// },
848 /// "available_credit_set_by": {
849 /// "examples": [
850 /// 1
851 /// ],
852 /// "type": [
853 /// "integer",
854 /// "null"
855 /// ]
856 /// },
857 /// "balance": {
858 /// "examples": [
859 /// 10000
860 /// ],
861 /// "type": [
862 /// "number",
863 /// "null"
864 /// ]
865 /// },
866 /// "balance_set_by": {
867 /// "examples": [
868 /// 1
869 /// ],
870 /// "type": [
871 /// "integer",
872 /// "null"
873 /// ]
874 /// },
875 /// "calculated_apr": {
876 /// "examples": [
877 /// 21.66409
878 /// ],
879 /// "type": [
880 /// "number",
881 /// "null"
882 /// ]
883 /// },
884 /// "cash_balance": {
885 /// "examples": [
886 /// 1000
887 /// ],
888 /// "type": [
889 /// "number",
890 /// "null"
891 /// ]
892 /// },
893 /// "cash_balance_set_by": {
894 /// "examples": [
895 /// 1
896 /// ],
897 /// "type": [
898 /// "integer",
899 /// "null"
900 /// ]
901 /// },
902 /// "cash_surrender_value": {
903 /// "examples": [
904 /// 1000
905 /// ],
906 /// "type": [
907 /// "number",
908 /// "null"
909 /// ]
910 /// },
911 /// "cash_surrender_value_set_by": {
912 /// "examples": [
913 /// 1
914 /// ],
915 /// "type": [
916 /// "integer",
917 /// "null"
918 /// ]
919 /// },
920 /// "created_at": {
921 /// "examples": [
922 /// "2023-07-25T17:14:46Z"
923 /// ],
924 /// "type": "string"
925 /// },
926 /// "credit_limit": {
927 /// "examples": [
928 /// 100
929 /// ],
930 /// "type": [
931 /// "number",
932 /// "null"
933 /// ]
934 /// },
935 /// "credit_limit_set_by": {
936 /// "examples": [
937 /// 1
938 /// ],
939 /// "type": [
940 /// "integer",
941 /// "null"
942 /// ]
943 /// },
944 /// "currency_code": {
945 /// "examples": [
946 /// "USD"
947 /// ],
948 /// "type": [
949 /// "string",
950 /// "null"
951 /// ]
952 /// },
953 /// "currency_code_set_by": {
954 /// "examples": [
955 /// 1
956 /// ],
957 /// "type": [
958 /// "integer",
959 /// "null"
960 /// ]
961 /// },
962 /// "day_payment_is_due": {
963 /// "examples": [
964 /// 20
965 /// ],
966 /// "type": [
967 /// "integer",
968 /// "null"
969 /// ]
970 /// },
971 /// "day_payment_is_due_set_by": {
972 /// "examples": [
973 /// 1
974 /// ],
975 /// "type": [
976 /// "integer",
977 /// "null"
978 /// ]
979 /// },
980 /// "death_benefit": {
981 /// "examples": [
982 /// 1000
983 /// ],
984 /// "type": [
985 /// "integer",
986 /// "null"
987 /// ]
988 /// },
989 /// "death_benefit_set_by": {
990 /// "examples": [
991 /// 1
992 /// ],
993 /// "type": [
994 /// "integer",
995 /// "null"
996 /// ]
997 /// },
998 /// "federal_insurance_status": {
999 /// "examples": [
1000 /// "INSURED"
1001 /// ],
1002 /// "type": [
1003 /// "string",
1004 /// "null"
1005 /// ]
1006 /// },
1007 /// "feed_account_number": {
1008 /// "examples": [
1009 /// "5366"
1010 /// ],
1011 /// "type": [
1012 /// "string",
1013 /// "null"
1014 /// ]
1015 /// },
1016 /// "feed_account_subtype": {
1017 /// "examples": [
1018 /// 1
1019 /// ],
1020 /// "type": [
1021 /// "integer",
1022 /// "null"
1023 /// ]
1024 /// },
1025 /// "feed_account_type": {
1026 /// "examples": [
1027 /// 1
1028 /// ],
1029 /// "type": [
1030 /// "integer",
1031 /// "null"
1032 /// ]
1033 /// },
1034 /// "feed_apr": {
1035 /// "examples": [
1036 /// 1
1037 /// ],
1038 /// "type": [
1039 /// "number",
1040 /// "null"
1041 /// ]
1042 /// },
1043 /// "feed_apy": {
1044 /// "examples": [
1045 /// 1
1046 /// ],
1047 /// "type": [
1048 /// "number",
1049 /// "null"
1050 /// ]
1051 /// },
1052 /// "feed_available_balance": {
1053 /// "examples": [
1054 /// 1000
1055 /// ],
1056 /// "type": [
1057 /// "number",
1058 /// "null"
1059 /// ]
1060 /// },
1061 /// "feed_balance": {
1062 /// "examples": [
1063 /// 1000
1064 /// ],
1065 /// "type": [
1066 /// "number",
1067 /// "null"
1068 /// ]
1069 /// },
1070 /// "feed_cash_balance": {
1071 /// "examples": [
1072 /// 1000
1073 /// ],
1074 /// "type": [
1075 /// "number",
1076 /// "null"
1077 /// ]
1078 /// },
1079 /// "feed_cash_surrender_value": {
1080 /// "examples": [
1081 /// 1000
1082 /// ],
1083 /// "type": [
1084 /// "number",
1085 /// "null"
1086 /// ]
1087 /// },
1088 /// "feed_credit_limit": {
1089 /// "examples": [
1090 /// 100
1091 /// ],
1092 /// "type": [
1093 /// "number",
1094 /// "null"
1095 /// ]
1096 /// },
1097 /// "feed_currency_code": {
1098 /// "examples": [
1099 /// "USD"
1100 /// ],
1101 /// "type": [
1102 /// "string",
1103 /// "null"
1104 /// ]
1105 /// },
1106 /// "feed_day_payment_is_due": {
1107 /// "examples": [
1108 /// 20
1109 /// ],
1110 /// "type": [
1111 /// "integer",
1112 /// "null"
1113 /// ]
1114 /// },
1115 /// "feed_death_benefit": {
1116 /// "examples": [
1117 /// 1000
1118 /// ],
1119 /// "type": [
1120 /// "integer",
1121 /// "null"
1122 /// ]
1123 /// },
1124 /// "feed_holdings_value": {
1125 /// "examples": [
1126 /// 1000
1127 /// ],
1128 /// "type": [
1129 /// "number",
1130 /// "null"
1131 /// ]
1132 /// },
1133 /// "feed_interest_rate": {
1134 /// "examples": [
1135 /// 1
1136 /// ],
1137 /// "type": [
1138 /// "number",
1139 /// "null"
1140 /// ]
1141 /// },
1142 /// "feed_is_closed": {
1143 /// "examples": [
1144 /// false
1145 /// ],
1146 /// "type": [
1147 /// "boolean",
1148 /// "null"
1149 /// ]
1150 /// },
1151 /// "feed_last_payment": {
1152 /// "examples": [
1153 /// 100
1154 /// ],
1155 /// "type": [
1156 /// "number",
1157 /// "null"
1158 /// ]
1159 /// },
1160 /// "feed_last_payment_at": {
1161 /// "examples": [
1162 /// "2023-07-25T17:14:46Z"
1163 /// ],
1164 /// "type": [
1165 /// "string",
1166 /// "null"
1167 /// ]
1168 /// },
1169 /// "feed_loan_amount": {
1170 /// "examples": [
1171 /// 1000
1172 /// ],
1173 /// "type": [
1174 /// "number",
1175 /// "null"
1176 /// ]
1177 /// },
1178 /// "feed_matures_on": {
1179 /// "examples": [
1180 /// "2015-10-13T17:57:37.000Z"
1181 /// ],
1182 /// "type": [
1183 /// "string",
1184 /// "null"
1185 /// ]
1186 /// },
1187 /// "feed_minimum_balance": {
1188 /// "examples": [
1189 /// 100
1190 /// ],
1191 /// "type": [
1192 /// "number",
1193 /// "null"
1194 /// ]
1195 /// },
1196 /// "feed_minimum_payment": {
1197 /// "examples": [
1198 /// 10
1199 /// ],
1200 /// "type": [
1201 /// "number",
1202 /// "null"
1203 /// ]
1204 /// },
1205 /// "feed_name": {
1206 /// "examples": [
1207 /// "Test account 2"
1208 /// ],
1209 /// "type": [
1210 /// "string",
1211 /// "null"
1212 /// ]
1213 /// },
1214 /// "feed_nickname": {
1215 /// "examples": [
1216 /// "My Checking"
1217 /// ],
1218 /// "type": [
1219 /// "string",
1220 /// "null"
1221 /// ]
1222 /// },
1223 /// "feed_original_balance": {
1224 /// "examples": [
1225 /// 10
1226 /// ],
1227 /// "type": [
1228 /// "number",
1229 /// "null"
1230 /// ]
1231 /// },
1232 /// "feed_payment_due_at": {
1233 /// "examples": [
1234 /// "2025-02-13T17:57:37.000Z"
1235 /// ],
1236 /// "type": [
1237 /// "string",
1238 /// "null"
1239 /// ]
1240 /// },
1241 /// "feed_payoff_balance": {
1242 /// "examples": [
1243 /// 10
1244 /// ],
1245 /// "type": [
1246 /// "number",
1247 /// "null"
1248 /// ]
1249 /// },
1250 /// "feed_routing_number": {
1251 /// "examples": [
1252 /// "68899990000000"
1253 /// ],
1254 /// "type": [
1255 /// "string",
1256 /// "null"
1257 /// ]
1258 /// },
1259 /// "feed_started_on": {
1260 /// "examples": [
1261 /// "2020-10-13T17:57:37.000Z"
1262 /// ],
1263 /// "type": [
1264 /// "string",
1265 /// "null"
1266 /// ]
1267 /// },
1268 /// "feed_statement_balance": {
1269 /// "examples": [
1270 /// 100
1271 /// ],
1272 /// "type": [
1273 /// "number",
1274 /// "null"
1275 /// ]
1276 /// },
1277 /// "feed_total_account_value": {
1278 /// "examples": [
1279 /// 100
1280 /// ],
1281 /// "type": [
1282 /// "number",
1283 /// "null"
1284 /// ]
1285 /// },
1286 /// "guid": {
1287 /// "examples": [
1288 /// "ACT-06d7f44b-caae-0f6e-1384-01f52e75dcb1"
1289 /// ],
1290 /// "type": [
1291 /// "string",
1292 /// "null"
1293 /// ]
1294 /// },
1295 /// "holdings_value": {
1296 /// "examples": [
1297 /// 1000
1298 /// ],
1299 /// "type": [
1300 /// "number",
1301 /// "null"
1302 /// ]
1303 /// },
1304 /// "holdings_value_set_by": {
1305 /// "examples": [
1306 /// 1
1307 /// ],
1308 /// "type": [
1309 /// "integer",
1310 /// "null"
1311 /// ]
1312 /// },
1313 /// "id": {
1314 /// "examples": [
1315 /// "1040434698"
1316 /// ],
1317 /// "type": [
1318 /// "string",
1319 /// "null"
1320 /// ]
1321 /// },
1322 /// "imported_at": {
1323 /// "examples": [
1324 /// "2015-10-13T17:57:37.000Z"
1325 /// ],
1326 /// "type": [
1327 /// "string",
1328 /// "null"
1329 /// ]
1330 /// },
1331 /// "institution_code": {
1332 /// "examples": [
1333 /// "3af3685e-05d9-7060-359f-008d0755e993"
1334 /// ],
1335 /// "type": [
1336 /// "string",
1337 /// "null"
1338 /// ]
1339 /// },
1340 /// "institution_guid": {
1341 /// "examples": [
1342 /// "INS-12a3b-4c5dd6-1349-008d0755e993"
1343 /// ],
1344 /// "type": [
1345 /// "string",
1346 /// "null"
1347 /// ]
1348 /// },
1349 /// "insured_name": {
1350 /// "examples": [
1351 /// "Tommy Shelby"
1352 /// ],
1353 /// "type": [
1354 /// "string",
1355 /// "null"
1356 /// ]
1357 /// },
1358 /// "interest_rate": {
1359 /// "examples": [
1360 /// 1
1361 /// ],
1362 /// "type": [
1363 /// "number",
1364 /// "null"
1365 /// ]
1366 /// },
1367 /// "interest_rate_set_by": {
1368 /// "examples": [
1369 /// 1
1370 /// ],
1371 /// "type": [
1372 /// "integer",
1373 /// "null"
1374 /// ]
1375 /// },
1376 /// "is_closed": {
1377 /// "examples": [
1378 /// false
1379 /// ],
1380 /// "type": [
1381 /// "boolean",
1382 /// "null"
1383 /// ]
1384 /// },
1385 /// "is_closed_set_by": {
1386 /// "examples": [
1387 /// 1
1388 /// ],
1389 /// "type": [
1390 /// "integer",
1391 /// "null"
1392 /// ]
1393 /// },
1394 /// "is_hidden": {
1395 /// "examples": [
1396 /// false
1397 /// ],
1398 /// "type": [
1399 /// "boolean",
1400 /// "null"
1401 /// ]
1402 /// },
1403 /// "is_manual": {
1404 /// "examples": [
1405 /// false
1406 /// ],
1407 /// "type": [
1408 /// "boolean",
1409 /// "null"
1410 /// ]
1411 /// },
1412 /// "last_payment": {
1413 /// "examples": [
1414 /// 100
1415 /// ],
1416 /// "type": [
1417 /// "number",
1418 /// "null"
1419 /// ]
1420 /// },
1421 /// "last_payment_at": {
1422 /// "examples": [
1423 /// "2023-07-25T17:14:46Z"
1424 /// ],
1425 /// "type": [
1426 /// "string",
1427 /// "null"
1428 /// ]
1429 /// },
1430 /// "last_payment_at_set_by": {
1431 /// "examples": [
1432 /// 1
1433 /// ],
1434 /// "type": [
1435 /// "integer",
1436 /// "null"
1437 /// ]
1438 /// },
1439 /// "last_payment_set_by": {
1440 /// "examples": [
1441 /// 1
1442 /// ],
1443 /// "type": [
1444 /// "integer",
1445 /// "null"
1446 /// ]
1447 /// },
1448 /// "loan_amount": {
1449 /// "examples": [
1450 /// 1000
1451 /// ],
1452 /// "type": [
1453 /// "number",
1454 /// "null"
1455 /// ]
1456 /// },
1457 /// "loan_amount_set_by": {
1458 /// "examples": [
1459 /// 1
1460 /// ],
1461 /// "type": [
1462 /// "integer",
1463 /// "null"
1464 /// ]
1465 /// },
1466 /// "margin_balance": {
1467 /// "examples": [
1468 /// 1000
1469 /// ],
1470 /// "type": [
1471 /// "number",
1472 /// "null"
1473 /// ]
1474 /// },
1475 /// "matures_on": {
1476 /// "examples": [
1477 /// "2015-10-13T17:57:37.000Z"
1478 /// ],
1479 /// "type": [
1480 /// "string",
1481 /// "null"
1482 /// ]
1483 /// },
1484 /// "matures_on_set_by": {
1485 /// "examples": [
1486 /// 1
1487 /// ],
1488 /// "type": [
1489 /// "integer",
1490 /// "null"
1491 /// ]
1492 /// },
1493 /// "member_guid": {
1494 /// "examples": [
1495 /// "MBR-7c6f361b-e582-15b6-60c0-358f12466b4b"
1496 /// ],
1497 /// "type": [
1498 /// "string",
1499 /// "null"
1500 /// ]
1501 /// },
1502 /// "member_id": {
1503 /// "examples": [
1504 /// "member123"
1505 /// ],
1506 /// "type": [
1507 /// "string",
1508 /// "null"
1509 /// ]
1510 /// },
1511 /// "member_is_managed_by_user": {
1512 /// "examples": [
1513 /// false
1514 /// ],
1515 /// "type": [
1516 /// "boolean",
1517 /// "null"
1518 /// ]
1519 /// },
1520 /// "metadata": {
1521 /// "examples": [
1522 /// "some metadata"
1523 /// ],
1524 /// "type": [
1525 /// "string",
1526 /// "null"
1527 /// ]
1528 /// },
1529 /// "minimum_balance": {
1530 /// "examples": [
1531 /// 100
1532 /// ],
1533 /// "type": [
1534 /// "number",
1535 /// "null"
1536 /// ]
1537 /// },
1538 /// "minimum_balance_set_by": {
1539 /// "examples": [
1540 /// 1
1541 /// ],
1542 /// "type": [
1543 /// "integer",
1544 /// "null"
1545 /// ]
1546 /// },
1547 /// "minimum_payment": {
1548 /// "examples": [
1549 /// 10
1550 /// ],
1551 /// "type": [
1552 /// "number",
1553 /// "null"
1554 /// ]
1555 /// },
1556 /// "minimum_payment_set_by": {
1557 /// "examples": [
1558 /// 1
1559 /// ],
1560 /// "type": [
1561 /// "integer",
1562 /// "null"
1563 /// ]
1564 /// },
1565 /// "name": {
1566 /// "examples": [
1567 /// "Test account 2"
1568 /// ],
1569 /// "type": [
1570 /// "string",
1571 /// "null"
1572 /// ]
1573 /// },
1574 /// "name_set_by": {
1575 /// "examples": [
1576 /// 1
1577 /// ],
1578 /// "type": [
1579 /// "integer",
1580 /// "null"
1581 /// ]
1582 /// },
1583 /// "nickname": {
1584 /// "examples": [
1585 /// "My Checking"
1586 /// ],
1587 /// "type": [
1588 /// "string",
1589 /// "null"
1590 /// ]
1591 /// },
1592 /// "nickname_set_by": {
1593 /// "examples": [
1594 /// 1
1595 /// ],
1596 /// "type": [
1597 /// "integer",
1598 /// "null"
1599 /// ]
1600 /// },
1601 /// "original_balance": {
1602 /// "examples": [
1603 /// 10
1604 /// ],
1605 /// "type": [
1606 /// "number",
1607 /// "null"
1608 /// ]
1609 /// },
1610 /// "original_balance_set_by": {
1611 /// "examples": [
1612 /// 1
1613 /// ],
1614 /// "type": [
1615 /// "integer",
1616 /// "null"
1617 /// ]
1618 /// },
1619 /// "pay_out_amount": {
1620 /// "examples": [
1621 /// 10
1622 /// ],
1623 /// "type": [
1624 /// "number",
1625 /// "null"
1626 /// ]
1627 /// },
1628 /// "payment_due_at": {
1629 /// "examples": [
1630 /// "2015-10-13T17:57:37.000Z"
1631 /// ],
1632 /// "type": [
1633 /// "string",
1634 /// "null"
1635 /// ]
1636 /// },
1637 /// "payment_due_at_set_by": {
1638 /// "examples": [
1639 /// 1
1640 /// ],
1641 /// "type": [
1642 /// "integer",
1643 /// "null"
1644 /// ]
1645 /// },
1646 /// "payoff_balance": {
1647 /// "examples": [
1648 /// 10
1649 /// ],
1650 /// "type": [
1651 /// "number",
1652 /// "null"
1653 /// ]
1654 /// },
1655 /// "payoff_balance_set_by": {
1656 /// "examples": [
1657 /// 1
1658 /// ],
1659 /// "type": [
1660 /// "integer",
1661 /// "null"
1662 /// ]
1663 /// },
1664 /// "premium_amount": {
1665 /// "examples": [
1666 /// 3900
1667 /// ],
1668 /// "type": [
1669 /// "number",
1670 /// "null"
1671 /// ]
1672 /// },
1673 /// "property_type": {
1674 /// "examples": [
1675 /// "VEHICLE"
1676 /// ],
1677 /// "type": [
1678 /// "string",
1679 /// "null"
1680 /// ]
1681 /// },
1682 /// "routing_number": {
1683 /// "examples": [
1684 /// "68899990000000"
1685 /// ],
1686 /// "type": [
1687 /// "string",
1688 /// "null"
1689 /// ]
1690 /// },
1691 /// "started_on": {
1692 /// "examples": [
1693 /// "2015-10-13T17:57:37.000Z"
1694 /// ],
1695 /// "type": [
1696 /// "string",
1697 /// "null"
1698 /// ]
1699 /// },
1700 /// "started_on_set_by": {
1701 /// "examples": [
1702 /// 1
1703 /// ],
1704 /// "type": [
1705 /// "integer",
1706 /// "null"
1707 /// ]
1708 /// },
1709 /// "statement_balance": {
1710 /// "examples": [
1711 /// 1000.5
1712 /// ],
1713 /// "type": [
1714 /// "number",
1715 /// "null"
1716 /// ]
1717 /// },
1718 /// "statement_balance_set_by": {
1719 /// "examples": [
1720 /// 1
1721 /// ],
1722 /// "type": [
1723 /// "integer",
1724 /// "null"
1725 /// ]
1726 /// },
1727 /// "subtype": {
1728 /// "examples": [
1729 /// "NONE"
1730 /// ],
1731 /// "type": [
1732 /// "string",
1733 /// "null"
1734 /// ]
1735 /// },
1736 /// "subtype_set_by": {
1737 /// "examples": [
1738 /// 1
1739 /// ],
1740 /// "type": [
1741 /// "integer",
1742 /// "null"
1743 /// ]
1744 /// },
1745 /// "today_ugl_amount": {
1746 /// "examples": [
1747 /// 1000.5
1748 /// ],
1749 /// "type": [
1750 /// "number",
1751 /// "null"
1752 /// ]
1753 /// },
1754 /// "today_ugl_percentage": {
1755 /// "examples": [
1756 /// 6.9
1757 /// ],
1758 /// "type": [
1759 /// "number",
1760 /// "null"
1761 /// ]
1762 /// },
1763 /// "total_account_value": {
1764 /// "examples": [
1765 /// 1
1766 /// ],
1767 /// "type": [
1768 /// "number",
1769 /// "null"
1770 /// ]
1771 /// },
1772 /// "total_account_value_set_by": {
1773 /// "examples": [
1774 /// 1
1775 /// ],
1776 /// "type": [
1777 /// "integer",
1778 /// "null"
1779 /// ]
1780 /// },
1781 /// "total_account_value_ugl": {
1782 /// "examples": [
1783 /// 1
1784 /// ],
1785 /// "type": [
1786 /// "number",
1787 /// "null"
1788 /// ]
1789 /// },
1790 /// "type": {
1791 /// "examples": [
1792 /// "SAVINGS"
1793 /// ],
1794 /// "type": [
1795 /// "string",
1796 /// "null"
1797 /// ]
1798 /// },
1799 /// "type_set_by": {
1800 /// "examples": [
1801 /// 1
1802 /// ],
1803 /// "type": [
1804 /// "integer",
1805 /// "null"
1806 /// ]
1807 /// },
1808 /// "updated_at": {
1809 /// "examples": [
1810 /// "2016-10-13T18:08:00.000Z"
1811 /// ],
1812 /// "type": [
1813 /// "string",
1814 /// "null"
1815 /// ]
1816 /// },
1817 /// "user_guid": {
1818 /// "examples": [
1819 /// "USR-fa7537f3-48aa-a683-a02a-b18940482f54"
1820 /// ],
1821 /// "type": [
1822 /// "string",
1823 /// "null"
1824 /// ]
1825 /// },
1826 /// "user_id": {
1827 /// "examples": [
1828 /// "user123"
1829 /// ],
1830 /// "type": [
1831 /// "string",
1832 /// "null"
1833 /// ]
1834 /// }
1835 /// }
1836 ///}
1837 /// ```
1838 /// </details>
1839 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
1840 pub struct AccountResponse {
1841 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1842 pub account_number: ::std::option::Option<::std::string::String>,
1843 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1844 pub account_number_set_by: ::std::option::Option<i64>,
1845 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1846 pub account_ownership: ::std::option::Option<::std::string::String>,
1847 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1848 pub annuity_policy_to_date: ::std::option::Option<::std::string::String>,
1849 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1850 pub annuity_provider: ::std::option::Option<::std::string::String>,
1851 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1852 pub annuity_term_year: ::std::option::Option<i64>,
1853 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1854 pub apr: ::std::option::Option<f64>,
1855 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1856 pub apr_set_by: ::std::option::Option<i64>,
1857 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1858 pub apy: ::std::option::Option<f64>,
1859 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1860 pub apy_set_by: ::std::option::Option<i64>,
1861 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1862 pub available_balance: ::std::option::Option<f64>,
1863 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1864 pub available_balance_set_by: ::std::option::Option<i64>,
1865 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1866 pub available_credit: ::std::option::Option<f64>,
1867 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1868 pub available_credit_set_by: ::std::option::Option<i64>,
1869 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1870 pub balance: ::std::option::Option<f64>,
1871 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1872 pub balance_set_by: ::std::option::Option<i64>,
1873 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1874 pub calculated_apr: ::std::option::Option<f64>,
1875 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1876 pub cash_balance: ::std::option::Option<f64>,
1877 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1878 pub cash_balance_set_by: ::std::option::Option<i64>,
1879 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1880 pub cash_surrender_value: ::std::option::Option<f64>,
1881 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1882 pub cash_surrender_value_set_by: ::std::option::Option<i64>,
1883 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1884 pub created_at: ::std::option::Option<::std::string::String>,
1885 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1886 pub credit_limit: ::std::option::Option<f64>,
1887 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1888 pub credit_limit_set_by: ::std::option::Option<i64>,
1889 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1890 pub currency_code: ::std::option::Option<::std::string::String>,
1891 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1892 pub currency_code_set_by: ::std::option::Option<i64>,
1893 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1894 pub day_payment_is_due: ::std::option::Option<i64>,
1895 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1896 pub day_payment_is_due_set_by: ::std::option::Option<i64>,
1897 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1898 pub death_benefit: ::std::option::Option<i64>,
1899 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1900 pub death_benefit_set_by: ::std::option::Option<i64>,
1901 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1902 pub federal_insurance_status: ::std::option::Option<::std::string::String>,
1903 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1904 pub feed_account_number: ::std::option::Option<::std::string::String>,
1905 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1906 pub feed_account_subtype: ::std::option::Option<i64>,
1907 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1908 pub feed_account_type: ::std::option::Option<i64>,
1909 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1910 pub feed_apr: ::std::option::Option<f64>,
1911 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1912 pub feed_apy: ::std::option::Option<f64>,
1913 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1914 pub feed_available_balance: ::std::option::Option<f64>,
1915 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1916 pub feed_balance: ::std::option::Option<f64>,
1917 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1918 pub feed_cash_balance: ::std::option::Option<f64>,
1919 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1920 pub feed_cash_surrender_value: ::std::option::Option<f64>,
1921 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1922 pub feed_credit_limit: ::std::option::Option<f64>,
1923 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1924 pub feed_currency_code: ::std::option::Option<::std::string::String>,
1925 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1926 pub feed_day_payment_is_due: ::std::option::Option<i64>,
1927 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1928 pub feed_death_benefit: ::std::option::Option<i64>,
1929 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1930 pub feed_holdings_value: ::std::option::Option<f64>,
1931 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1932 pub feed_interest_rate: ::std::option::Option<f64>,
1933 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1934 pub feed_is_closed: ::std::option::Option<bool>,
1935 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1936 pub feed_last_payment: ::std::option::Option<f64>,
1937 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1938 pub feed_last_payment_at: ::std::option::Option<::std::string::String>,
1939 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1940 pub feed_loan_amount: ::std::option::Option<f64>,
1941 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1942 pub feed_matures_on: ::std::option::Option<::std::string::String>,
1943 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1944 pub feed_minimum_balance: ::std::option::Option<f64>,
1945 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1946 pub feed_minimum_payment: ::std::option::Option<f64>,
1947 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1948 pub feed_name: ::std::option::Option<::std::string::String>,
1949 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1950 pub feed_nickname: ::std::option::Option<::std::string::String>,
1951 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1952 pub feed_original_balance: ::std::option::Option<f64>,
1953 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1954 pub feed_payment_due_at: ::std::option::Option<::std::string::String>,
1955 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1956 pub feed_payoff_balance: ::std::option::Option<f64>,
1957 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1958 pub feed_routing_number: ::std::option::Option<::std::string::String>,
1959 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1960 pub feed_started_on: ::std::option::Option<::std::string::String>,
1961 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1962 pub feed_statement_balance: ::std::option::Option<f64>,
1963 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1964 pub feed_total_account_value: ::std::option::Option<f64>,
1965 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1966 pub guid: ::std::option::Option<::std::string::String>,
1967 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1968 pub holdings_value: ::std::option::Option<f64>,
1969 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1970 pub holdings_value_set_by: ::std::option::Option<i64>,
1971 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1972 pub id: ::std::option::Option<::std::string::String>,
1973 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1974 pub imported_at: ::std::option::Option<::std::string::String>,
1975 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1976 pub institution_code: ::std::option::Option<::std::string::String>,
1977 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1978 pub institution_guid: ::std::option::Option<::std::string::String>,
1979 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1980 pub insured_name: ::std::option::Option<::std::string::String>,
1981 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1982 pub interest_rate: ::std::option::Option<f64>,
1983 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1984 pub interest_rate_set_by: ::std::option::Option<i64>,
1985 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1986 pub is_closed: ::std::option::Option<bool>,
1987 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1988 pub is_closed_set_by: ::std::option::Option<i64>,
1989 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1990 pub is_hidden: ::std::option::Option<bool>,
1991 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1992 pub is_manual: ::std::option::Option<bool>,
1993 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1994 pub last_payment: ::std::option::Option<f64>,
1995 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1996 pub last_payment_at: ::std::option::Option<::std::string::String>,
1997 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
1998 pub last_payment_at_set_by: ::std::option::Option<i64>,
1999 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2000 pub last_payment_set_by: ::std::option::Option<i64>,
2001 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2002 pub loan_amount: ::std::option::Option<f64>,
2003 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2004 pub loan_amount_set_by: ::std::option::Option<i64>,
2005 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2006 pub margin_balance: ::std::option::Option<f64>,
2007 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2008 pub matures_on: ::std::option::Option<::std::string::String>,
2009 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2010 pub matures_on_set_by: ::std::option::Option<i64>,
2011 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2012 pub member_guid: ::std::option::Option<::std::string::String>,
2013 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2014 pub member_id: ::std::option::Option<::std::string::String>,
2015 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2016 pub member_is_managed_by_user: ::std::option::Option<bool>,
2017 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2018 pub metadata: ::std::option::Option<::std::string::String>,
2019 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2020 pub minimum_balance: ::std::option::Option<f64>,
2021 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2022 pub minimum_balance_set_by: ::std::option::Option<i64>,
2023 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2024 pub minimum_payment: ::std::option::Option<f64>,
2025 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2026 pub minimum_payment_set_by: ::std::option::Option<i64>,
2027 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2028 pub name: ::std::option::Option<::std::string::String>,
2029 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2030 pub name_set_by: ::std::option::Option<i64>,
2031 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2032 pub nickname: ::std::option::Option<::std::string::String>,
2033 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2034 pub nickname_set_by: ::std::option::Option<i64>,
2035 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2036 pub original_balance: ::std::option::Option<f64>,
2037 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2038 pub original_balance_set_by: ::std::option::Option<i64>,
2039 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2040 pub pay_out_amount: ::std::option::Option<f64>,
2041 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2042 pub payment_due_at: ::std::option::Option<::std::string::String>,
2043 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2044 pub payment_due_at_set_by: ::std::option::Option<i64>,
2045 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2046 pub payoff_balance: ::std::option::Option<f64>,
2047 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2048 pub payoff_balance_set_by: ::std::option::Option<i64>,
2049 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2050 pub premium_amount: ::std::option::Option<f64>,
2051 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2052 pub property_type: ::std::option::Option<::std::string::String>,
2053 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2054 pub routing_number: ::std::option::Option<::std::string::String>,
2055 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2056 pub started_on: ::std::option::Option<::std::string::String>,
2057 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2058 pub started_on_set_by: ::std::option::Option<i64>,
2059 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2060 pub statement_balance: ::std::option::Option<f64>,
2061 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2062 pub statement_balance_set_by: ::std::option::Option<i64>,
2063 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2064 pub subtype: ::std::option::Option<::std::string::String>,
2065 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2066 pub subtype_set_by: ::std::option::Option<i64>,
2067 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2068 pub today_ugl_amount: ::std::option::Option<f64>,
2069 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2070 pub today_ugl_percentage: ::std::option::Option<f64>,
2071 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2072 pub total_account_value: ::std::option::Option<f64>,
2073 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2074 pub total_account_value_set_by: ::std::option::Option<i64>,
2075 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2076 pub total_account_value_ugl: ::std::option::Option<f64>,
2077 #[serde(
2078 rename = "type",
2079 default,
2080 skip_serializing_if = "::std::option::Option::is_none"
2081 )]
2082 pub type_: ::std::option::Option<::std::string::String>,
2083 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2084 pub type_set_by: ::std::option::Option<i64>,
2085 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2086 pub updated_at: ::std::option::Option<::std::string::String>,
2087 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2088 pub user_guid: ::std::option::Option<::std::string::String>,
2089 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2090 pub user_id: ::std::option::Option<::std::string::String>,
2091 }
2092
2093 impl ::std::convert::From<&AccountResponse> for AccountResponse {
2094 fn from(value: &AccountResponse) -> Self {
2095 value.clone()
2096 }
2097 }
2098
2099 impl ::std::default::Default for AccountResponse {
2100 fn default() -> Self {
2101 Self {
2102 account_number: Default::default(),
2103 account_number_set_by: Default::default(),
2104 account_ownership: Default::default(),
2105 annuity_policy_to_date: Default::default(),
2106 annuity_provider: Default::default(),
2107 annuity_term_year: Default::default(),
2108 apr: Default::default(),
2109 apr_set_by: Default::default(),
2110 apy: Default::default(),
2111 apy_set_by: Default::default(),
2112 available_balance: Default::default(),
2113 available_balance_set_by: Default::default(),
2114 available_credit: Default::default(),
2115 available_credit_set_by: Default::default(),
2116 balance: Default::default(),
2117 balance_set_by: Default::default(),
2118 calculated_apr: Default::default(),
2119 cash_balance: Default::default(),
2120 cash_balance_set_by: Default::default(),
2121 cash_surrender_value: Default::default(),
2122 cash_surrender_value_set_by: Default::default(),
2123 created_at: Default::default(),
2124 credit_limit: Default::default(),
2125 credit_limit_set_by: Default::default(),
2126 currency_code: Default::default(),
2127 currency_code_set_by: Default::default(),
2128 day_payment_is_due: Default::default(),
2129 day_payment_is_due_set_by: Default::default(),
2130 death_benefit: Default::default(),
2131 death_benefit_set_by: Default::default(),
2132 federal_insurance_status: Default::default(),
2133 feed_account_number: Default::default(),
2134 feed_account_subtype: Default::default(),
2135 feed_account_type: Default::default(),
2136 feed_apr: Default::default(),
2137 feed_apy: Default::default(),
2138 feed_available_balance: Default::default(),
2139 feed_balance: Default::default(),
2140 feed_cash_balance: Default::default(),
2141 feed_cash_surrender_value: Default::default(),
2142 feed_credit_limit: Default::default(),
2143 feed_currency_code: Default::default(),
2144 feed_day_payment_is_due: Default::default(),
2145 feed_death_benefit: Default::default(),
2146 feed_holdings_value: Default::default(),
2147 feed_interest_rate: Default::default(),
2148 feed_is_closed: Default::default(),
2149 feed_last_payment: Default::default(),
2150 feed_last_payment_at: Default::default(),
2151 feed_loan_amount: Default::default(),
2152 feed_matures_on: Default::default(),
2153 feed_minimum_balance: Default::default(),
2154 feed_minimum_payment: Default::default(),
2155 feed_name: Default::default(),
2156 feed_nickname: Default::default(),
2157 feed_original_balance: Default::default(),
2158 feed_payment_due_at: Default::default(),
2159 feed_payoff_balance: Default::default(),
2160 feed_routing_number: Default::default(),
2161 feed_started_on: Default::default(),
2162 feed_statement_balance: Default::default(),
2163 feed_total_account_value: Default::default(),
2164 guid: Default::default(),
2165 holdings_value: Default::default(),
2166 holdings_value_set_by: Default::default(),
2167 id: Default::default(),
2168 imported_at: Default::default(),
2169 institution_code: Default::default(),
2170 institution_guid: Default::default(),
2171 insured_name: Default::default(),
2172 interest_rate: Default::default(),
2173 interest_rate_set_by: Default::default(),
2174 is_closed: Default::default(),
2175 is_closed_set_by: Default::default(),
2176 is_hidden: Default::default(),
2177 is_manual: Default::default(),
2178 last_payment: Default::default(),
2179 last_payment_at: Default::default(),
2180 last_payment_at_set_by: Default::default(),
2181 last_payment_set_by: Default::default(),
2182 loan_amount: Default::default(),
2183 loan_amount_set_by: Default::default(),
2184 margin_balance: Default::default(),
2185 matures_on: Default::default(),
2186 matures_on_set_by: Default::default(),
2187 member_guid: Default::default(),
2188 member_id: Default::default(),
2189 member_is_managed_by_user: Default::default(),
2190 metadata: Default::default(),
2191 minimum_balance: Default::default(),
2192 minimum_balance_set_by: Default::default(),
2193 minimum_payment: Default::default(),
2194 minimum_payment_set_by: Default::default(),
2195 name: Default::default(),
2196 name_set_by: Default::default(),
2197 nickname: Default::default(),
2198 nickname_set_by: Default::default(),
2199 original_balance: Default::default(),
2200 original_balance_set_by: Default::default(),
2201 pay_out_amount: Default::default(),
2202 payment_due_at: Default::default(),
2203 payment_due_at_set_by: Default::default(),
2204 payoff_balance: Default::default(),
2205 payoff_balance_set_by: Default::default(),
2206 premium_amount: Default::default(),
2207 property_type: Default::default(),
2208 routing_number: Default::default(),
2209 started_on: Default::default(),
2210 started_on_set_by: Default::default(),
2211 statement_balance: Default::default(),
2212 statement_balance_set_by: Default::default(),
2213 subtype: Default::default(),
2214 subtype_set_by: Default::default(),
2215 today_ugl_amount: Default::default(),
2216 today_ugl_percentage: Default::default(),
2217 total_account_value: Default::default(),
2218 total_account_value_set_by: Default::default(),
2219 total_account_value_ugl: Default::default(),
2220 type_: Default::default(),
2221 type_set_by: Default::default(),
2222 updated_at: Default::default(),
2223 user_guid: Default::default(),
2224 user_id: Default::default(),
2225 }
2226 }
2227 }
2228
2229 ///`AccountResponseBody`
2230 ///
2231 /// <details><summary>JSON schema</summary>
2232 ///
2233 /// ```json
2234 ///{
2235 /// "type": "object",
2236 /// "properties": {
2237 /// "account": {
2238 /// "$ref": "#/components/schemas/AccountResponse"
2239 /// }
2240 /// }
2241 ///}
2242 /// ```
2243 /// </details>
2244 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
2245 pub struct AccountResponseBody {
2246 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2247 pub account: ::std::option::Option<AccountResponse>,
2248 }
2249
2250 impl ::std::convert::From<&AccountResponseBody> for AccountResponseBody {
2251 fn from(value: &AccountResponseBody) -> Self {
2252 value.clone()
2253 }
2254 }
2255
2256 impl ::std::default::Default for AccountResponseBody {
2257 fn default() -> Self {
2258 Self {
2259 account: Default::default(),
2260 }
2261 }
2262 }
2263
2264 ///`AccountUpdateRequest`
2265 ///
2266 /// <details><summary>JSON schema</summary>
2267 ///
2268 /// ```json
2269 ///{
2270 /// "type": "object",
2271 /// "properties": {
2272 /// "account_subtype": {
2273 /// "description": "Can only be updated for manual accounts.",
2274 /// "examples": [
2275 /// "PERSONAL"
2276 /// ],
2277 /// "type": "string"
2278 /// },
2279 /// "account_type": {
2280 /// "description": "Can only be updated for manual accounts.",
2281 /// "examples": [
2282 /// "SAVINGS"
2283 /// ],
2284 /// "type": "string"
2285 /// },
2286 /// "apr": {
2287 /// "description": "Can only be updated for manual accounts.",
2288 /// "examples": [
2289 /// 1
2290 /// ],
2291 /// "type": "number"
2292 /// },
2293 /// "apy": {
2294 /// "description": "Can only be updated for manual accounts.",
2295 /// "examples": [
2296 /// 1
2297 /// ],
2298 /// "type": "number"
2299 /// },
2300 /// "available_balance": {
2301 /// "description": "Can only be updated for manual accounts.",
2302 /// "examples": [
2303 /// 1000
2304 /// ],
2305 /// "type": "number"
2306 /// },
2307 /// "balance": {
2308 /// "description": "Can only be updated for manual accounts.",
2309 /// "examples": [
2310 /// 1000
2311 /// ],
2312 /// "type": "number"
2313 /// },
2314 /// "cash_surrender_value": {
2315 /// "description": "Can only be updated for manual accounts.",
2316 /// "examples": [
2317 /// 1000
2318 /// ],
2319 /// "type": "number"
2320 /// },
2321 /// "credit_limit": {
2322 /// "description": "Can only be updated for manual accounts.",
2323 /// "examples": [
2324 /// 100
2325 /// ],
2326 /// "type": "number"
2327 /// },
2328 /// "currency_code": {
2329 /// "description": "Can only be updated for manual accounts.",
2330 /// "examples": [
2331 /// "USD"
2332 /// ],
2333 /// "type": "string"
2334 /// },
2335 /// "death_benefit": {
2336 /// "description": "Can only be updated for manual accounts.",
2337 /// "examples": [
2338 /// 1000
2339 /// ],
2340 /// "type": "integer"
2341 /// },
2342 /// "interest_rate": {
2343 /// "description": "Can only be updated for manual accounts.",
2344 /// "examples": [
2345 /// 1
2346 /// ],
2347 /// "type": "number"
2348 /// },
2349 /// "is_business": {
2350 /// "description": "Can be updated for manual accounts and aggregated
2351 /// accounts.",
2352 /// "examples": [
2353 /// false
2354 /// ],
2355 /// "type": "boolean"
2356 /// },
2357 /// "is_closed": {
2358 /// "description": "Can only be updated for manual accounts.",
2359 /// "examples": [
2360 /// false
2361 /// ],
2362 /// "type": "boolean"
2363 /// },
2364 /// "is_hidden": {
2365 /// "description": "Can be updated for manual accounts and aggregated
2366 /// accounts.",
2367 /// "examples": [
2368 /// false
2369 /// ],
2370 /// "type": "boolean"
2371 /// },
2372 /// "loan_amount": {
2373 /// "description": "Can only be updated for manual accounts.",
2374 /// "examples": [
2375 /// 1000
2376 /// ],
2377 /// "type": "number"
2378 /// },
2379 /// "metadata": {
2380 /// "description": "Can only be updated for manual accounts.",
2381 /// "examples": [
2382 /// "some metadata"
2383 /// ],
2384 /// "type": "string"
2385 /// },
2386 /// "name": {
2387 /// "description": "Can only be updated for manual accounts.",
2388 /// "examples": [
2389 /// "Test account 2"
2390 /// ],
2391 /// "type": "string"
2392 /// },
2393 /// "nickname": {
2394 /// "description": "Can only be updated for manual accounts.",
2395 /// "examples": [
2396 /// "Swiss Account"
2397 /// ],
2398 /// "type": "string"
2399 /// },
2400 /// "original_balance": {
2401 /// "description": "Can only be updated for manual accounts.",
2402 /// "examples": [
2403 /// 10
2404 /// ],
2405 /// "type": "number"
2406 /// },
2407 /// "property_type": {
2408 /// "description": "Can only be updated for manual accounts.",
2409 /// "examples": [
2410 /// "VEHICLE"
2411 /// ],
2412 /// "type": "string"
2413 /// },
2414 /// "skip_webhook": {
2415 /// "description": "If set to true, prevents sending an account webhook
2416 /// for the update if that webhook type is enabled for you.",
2417 /// "examples": [
2418 /// true
2419 /// ],
2420 /// "type": "boolean"
2421 /// }
2422 /// }
2423 ///}
2424 /// ```
2425 /// </details>
2426 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
2427 pub struct AccountUpdateRequest {
2428 ///Can only be updated for manual accounts.
2429 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2430 pub account_subtype: ::std::option::Option<::std::string::String>,
2431 ///Can only be updated for manual accounts.
2432 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2433 pub account_type: ::std::option::Option<::std::string::String>,
2434 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2435 pub apr: ::std::option::Option<f64>,
2436 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2437 pub apy: ::std::option::Option<f64>,
2438 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2439 pub available_balance: ::std::option::Option<f64>,
2440 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2441 pub balance: ::std::option::Option<f64>,
2442 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2443 pub cash_surrender_value: ::std::option::Option<f64>,
2444 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2445 pub credit_limit: ::std::option::Option<f64>,
2446 ///Can only be updated for manual accounts.
2447 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2448 pub currency_code: ::std::option::Option<::std::string::String>,
2449 ///Can only be updated for manual accounts.
2450 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2451 pub death_benefit: ::std::option::Option<i64>,
2452 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2453 pub interest_rate: ::std::option::Option<f64>,
2454 ///Can be updated for manual accounts and aggregated accounts.
2455 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2456 pub is_business: ::std::option::Option<bool>,
2457 ///Can only be updated for manual accounts.
2458 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2459 pub is_closed: ::std::option::Option<bool>,
2460 ///Can be updated for manual accounts and aggregated accounts.
2461 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2462 pub is_hidden: ::std::option::Option<bool>,
2463 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2464 pub loan_amount: ::std::option::Option<f64>,
2465 ///Can only be updated for manual accounts.
2466 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2467 pub metadata: ::std::option::Option<::std::string::String>,
2468 ///Can only be updated for manual accounts.
2469 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2470 pub name: ::std::option::Option<::std::string::String>,
2471 ///Can only be updated for manual accounts.
2472 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2473 pub nickname: ::std::option::Option<::std::string::String>,
2474 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2475 pub original_balance: ::std::option::Option<f64>,
2476 ///Can only be updated for manual accounts.
2477 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2478 pub property_type: ::std::option::Option<::std::string::String>,
2479 ///If set to true, prevents sending an account webhook for the update
2480 /// if that webhook type is enabled for you.
2481 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2482 pub skip_webhook: ::std::option::Option<bool>,
2483 }
2484
2485 impl ::std::convert::From<&AccountUpdateRequest> for AccountUpdateRequest {
2486 fn from(value: &AccountUpdateRequest) -> Self {
2487 value.clone()
2488 }
2489 }
2490
2491 impl ::std::default::Default for AccountUpdateRequest {
2492 fn default() -> Self {
2493 Self {
2494 account_subtype: Default::default(),
2495 account_type: Default::default(),
2496 apr: Default::default(),
2497 apy: Default::default(),
2498 available_balance: Default::default(),
2499 balance: Default::default(),
2500 cash_surrender_value: Default::default(),
2501 credit_limit: Default::default(),
2502 currency_code: Default::default(),
2503 death_benefit: Default::default(),
2504 interest_rate: Default::default(),
2505 is_business: Default::default(),
2506 is_closed: Default::default(),
2507 is_hidden: Default::default(),
2508 loan_amount: Default::default(),
2509 metadata: Default::default(),
2510 name: Default::default(),
2511 nickname: Default::default(),
2512 original_balance: Default::default(),
2513 property_type: Default::default(),
2514 skip_webhook: Default::default(),
2515 }
2516 }
2517 }
2518
2519 ///`AccountUpdateRequestBody`
2520 ///
2521 /// <details><summary>JSON schema</summary>
2522 ///
2523 /// ```json
2524 ///{
2525 /// "type": "object",
2526 /// "properties": {
2527 /// "account": {
2528 /// "$ref": "#/components/schemas/AccountUpdateRequest"
2529 /// }
2530 /// }
2531 ///}
2532 /// ```
2533 /// </details>
2534 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
2535 pub struct AccountUpdateRequestBody {
2536 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2537 pub account: ::std::option::Option<AccountUpdateRequest>,
2538 }
2539
2540 impl ::std::convert::From<&AccountUpdateRequestBody> for AccountUpdateRequestBody {
2541 fn from(value: &AccountUpdateRequestBody) -> Self {
2542 value.clone()
2543 }
2544 }
2545
2546 impl ::std::default::Default for AccountUpdateRequestBody {
2547 fn default() -> Self {
2548 Self {
2549 account: Default::default(),
2550 }
2551 }
2552 }
2553
2554 ///`AccountsResponseBody`
2555 ///
2556 /// <details><summary>JSON schema</summary>
2557 ///
2558 /// ```json
2559 ///{
2560 /// "type": "object",
2561 /// "properties": {
2562 /// "accounts": {
2563 /// "type": "array",
2564 /// "items": {
2565 /// "$ref": "#/components/schemas/AccountResponse"
2566 /// }
2567 /// },
2568 /// "pagination": {
2569 /// "$ref": "#/components/schemas/PaginationResponse"
2570 /// }
2571 /// }
2572 ///}
2573 /// ```
2574 /// </details>
2575 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
2576 pub struct AccountsResponseBody {
2577 #[serde(default, skip_serializing_if = "::std::vec::Vec::is_empty")]
2578 pub accounts: ::std::vec::Vec<AccountResponse>,
2579 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2580 pub pagination: ::std::option::Option<PaginationResponse>,
2581 }
2582
2583 impl ::std::convert::From<&AccountsResponseBody> for AccountsResponseBody {
2584 fn from(value: &AccountsResponseBody) -> Self {
2585 value.clone()
2586 }
2587 }
2588
2589 impl ::std::default::Default for AccountsResponseBody {
2590 fn default() -> Self {
2591 Self {
2592 accounts: Default::default(),
2593 pagination: Default::default(),
2594 }
2595 }
2596 }
2597
2598 ///`AchResponse`
2599 ///
2600 /// <details><summary>JSON schema</summary>
2601 ///
2602 /// ```json
2603 ///{
2604 /// "type": "object",
2605 /// "properties": {
2606 /// "account_guid": {
2607 /// "examples": [
2608 /// "ACT-06d7f44b-caae-0f6e-1384-01f52e75dcb1"
2609 /// ],
2610 /// "type": "string"
2611 /// },
2612 /// "account_number_last_four": {
2613 /// "examples": [
2614 /// "1234"
2615 /// ],
2616 /// "type": [
2617 /// "string",
2618 /// "null"
2619 /// ]
2620 /// },
2621 /// "account_type": {
2622 /// "examples": [
2623 /// "CREDIT"
2624 /// ],
2625 /// "type": [
2626 /// "string",
2627 /// "null"
2628 /// ]
2629 /// },
2630 /// "ach_initiated_at": {
2631 /// "examples": [
2632 /// "2025-02-13T18:08:00+00:00"
2633 /// ],
2634 /// "type": [
2635 /// "string",
2636 /// "null"
2637 /// ]
2638 /// },
2639 /// "client_guid": {
2640 /// "examples": [
2641 /// "CLT-abcd-1234"
2642 /// ],
2643 /// "type": "string"
2644 /// },
2645 /// "corrected_account_number": {
2646 /// "type": [
2647 /// "string",
2648 /// "null"
2649 /// ]
2650 /// },
2651 /// "corrected_routing_number": {
2652 /// "type": [
2653 /// "string",
2654 /// "null"
2655 /// ]
2656 /// },
2657 /// "created_at": {
2658 /// "type": "string"
2659 /// },
2660 /// "guid": {
2661 /// "examples": [
2662 /// "ACH-d74cb14f-fd0a-449f-991b-e0362a63d9c6"
2663 /// ],
2664 /// "type": "string"
2665 /// },
2666 /// "id": {
2667 /// "examples": [
2668 /// "client_ach_return_id_1234"
2669 /// ],
2670 /// "type": "string"
2671 /// },
2672 /// "institution_guid": {
2673 /// "examples": [
2674 /// "INS-34r4f44b-cfge-0f6e-3484-21f47e45tfv7"
2675 /// ],
2676 /// "type": "string"
2677 /// },
2678 /// "investigation_notes": {
2679 /// "type": [
2680 /// "string",
2681 /// "null"
2682 /// ]
2683 /// },
2684 /// "member_guid": {
2685 /// "examples": [
2686 /// "MBR-7c6f361b-e582-15b6-60c0-358f12466b4b"
2687 /// ],
2688 /// "type": "string"
2689 /// },
2690 /// "processing_errors": {
2691 /// "type": [
2692 /// "string",
2693 /// "null"
2694 /// ]
2695 /// },
2696 /// "resolution_code": {
2697 /// "type": [
2698 /// "string",
2699 /// "null"
2700 /// ]
2701 /// },
2702 /// "resolution_detail": {
2703 /// "type": [
2704 /// "string",
2705 /// "null"
2706 /// ]
2707 /// },
2708 /// "resolved_status_at": {
2709 /// "type": [
2710 /// "string",
2711 /// "null"
2712 /// ]
2713 /// },
2714 /// "return_account_number": {
2715 /// "type": [
2716 /// "string",
2717 /// "null"
2718 /// ]
2719 /// },
2720 /// "return_code": {
2721 /// "examples": [
2722 /// "R01"
2723 /// ],
2724 /// "type": "string"
2725 /// },
2726 /// "return_notes": {
2727 /// "type": [
2728 /// "string",
2729 /// "null"
2730 /// ]
2731 /// },
2732 /// "return_routing_number": {
2733 /// "type": [
2734 /// "string",
2735 /// "null"
2736 /// ]
2737 /// },
2738 /// "return_status": {
2739 /// "examples": [
2740 /// "SUBMITTED"
2741 /// ],
2742 /// "type": [
2743 /// "string",
2744 /// "null"
2745 /// ]
2746 /// },
2747 /// "returned_at": {
2748 /// "examples": [
2749 /// "2025-02-13T18:09:00+00:00"
2750 /// ],
2751 /// "type": [
2752 /// "string",
2753 /// "null"
2754 /// ]
2755 /// },
2756 /// "sec_code": {
2757 /// "examples": [
2758 /// "PPD"
2759 /// ],
2760 /// "type": [
2761 /// "string",
2762 /// "null"
2763 /// ]
2764 /// },
2765 /// "started_processing_at": {
2766 /// "type": [
2767 /// "string",
2768 /// "null"
2769 /// ]
2770 /// },
2771 /// "submitted_at": {
2772 /// "type": [
2773 /// "string",
2774 /// "null"
2775 /// ]
2776 /// },
2777 /// "transaction_amount": {
2778 /// "examples": [
2779 /// 225.84
2780 /// ],
2781 /// "type": [
2782 /// "number",
2783 /// "null"
2784 /// ],
2785 /// "format": "double"
2786 /// },
2787 /// "updated_at": {
2788 /// "type": "string"
2789 /// },
2790 /// "user_guid": {
2791 /// "examples": [
2792 /// "USR-fa7537f3-48aa-a683-a02a-b18940482f54"
2793 /// ],
2794 /// "type": "string"
2795 /// }
2796 /// }
2797 ///}
2798 /// ```
2799 /// </details>
2800 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
2801 pub struct AchResponse {
2802 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2803 pub account_guid: ::std::option::Option<::std::string::String>,
2804 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2805 pub account_number_last_four: ::std::option::Option<::std::string::String>,
2806 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2807 pub account_type: ::std::option::Option<::std::string::String>,
2808 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2809 pub ach_initiated_at: ::std::option::Option<::std::string::String>,
2810 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2811 pub client_guid: ::std::option::Option<::std::string::String>,
2812 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2813 pub corrected_account_number: ::std::option::Option<::std::string::String>,
2814 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2815 pub corrected_routing_number: ::std::option::Option<::std::string::String>,
2816 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2817 pub created_at: ::std::option::Option<::std::string::String>,
2818 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2819 pub guid: ::std::option::Option<::std::string::String>,
2820 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2821 pub id: ::std::option::Option<::std::string::String>,
2822 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2823 pub institution_guid: ::std::option::Option<::std::string::String>,
2824 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2825 pub investigation_notes: ::std::option::Option<::std::string::String>,
2826 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2827 pub member_guid: ::std::option::Option<::std::string::String>,
2828 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2829 pub processing_errors: ::std::option::Option<::std::string::String>,
2830 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2831 pub resolution_code: ::std::option::Option<::std::string::String>,
2832 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2833 pub resolution_detail: ::std::option::Option<::std::string::String>,
2834 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2835 pub resolved_status_at: ::std::option::Option<::std::string::String>,
2836 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2837 pub return_account_number: ::std::option::Option<::std::string::String>,
2838 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2839 pub return_code: ::std::option::Option<::std::string::String>,
2840 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2841 pub return_notes: ::std::option::Option<::std::string::String>,
2842 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2843 pub return_routing_number: ::std::option::Option<::std::string::String>,
2844 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2845 pub return_status: ::std::option::Option<::std::string::String>,
2846 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2847 pub returned_at: ::std::option::Option<::std::string::String>,
2848 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2849 pub sec_code: ::std::option::Option<::std::string::String>,
2850 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2851 pub started_processing_at: ::std::option::Option<::std::string::String>,
2852 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2853 pub submitted_at: ::std::option::Option<::std::string::String>,
2854 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2855 pub transaction_amount: ::std::option::Option<f64>,
2856 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2857 pub updated_at: ::std::option::Option<::std::string::String>,
2858 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
2859 pub user_guid: ::std::option::Option<::std::string::String>,
2860 }
2861
2862 impl ::std::convert::From<&AchResponse> for AchResponse {
2863 fn from(value: &AchResponse) -> Self {
2864 value.clone()
2865 }
2866 }
2867
2868 impl ::std::default::Default for AchResponse {
2869 fn default() -> Self {
2870 Self {
2871 account_guid: Default::default(),
2872 account_number_last_four: Default::default(),
2873 account_type: Default::default(),
2874 ach_initiated_at: Default::default(),
2875 client_guid: Default::default(),
2876 corrected_account_number: Default::default(),
2877 corrected_routing_number: Default::default(),
2878 created_at: Default::default(),
2879 guid: Default::default(),
2880 id: Default::default(),
2881 institution_guid: Default::default(),
2882 investigation_notes: Default::default(),
2883 member_guid: Default::default(),
2884 processing_errors: Default::default(),
2885 resolution_code: Default::default(),
2886 resolution_detail: Default::default(),
2887 resolved_status_at: Default::default(),
2888 return_account_number: Default::default(),
2889 return_code: Default::default(),
2890 return_notes: Default::default(),
2891 return_routing_number: Default::default(),
2892 return_status: Default::default(),
2893 returned_at: Default::default(),
2894 sec_code: Default::default(),
2895 started_processing_at: Default::default(),
2896 submitted_at: Default::default(),
2897 transaction_amount: Default::default(),
2898 updated_at: Default::default(),
2899 user_guid: Default::default(),
2900 }
2901 }
2902 }
2903
2904 ///`AchReturnCreateRequest`
2905 ///
2906 /// <details><summary>JSON schema</summary>
2907 ///
2908 /// ```json
2909 ///{
2910 /// "required": [
2911 /// "account_guid",
2912 /// "id",
2913 /// "member_guid",
2914 /// "return_code",
2915 /// "user_guid"
2916 /// ],
2917 /// "properties": {
2918 /// "account_guid": {
2919 /// "description": "The unique identifier for the account associated
2920 /// with the transaction. Defined by MX.",
2921 /// "examples": [
2922 /// "ACT-06d7f44b-caae-0f6e-1384-01f52e75dcb1"
2923 /// ],
2924 /// "type": "string"
2925 /// },
2926 /// "account_number_last_four": {
2927 /// "description": "The last 4 digits of the account number used for
2928 /// the transaction by the Originating Depository Financial Institution
2929 /// (ODFI).",
2930 /// "examples": [
2931 /// "1234"
2932 /// ],
2933 /// "type": "string"
2934 /// },
2935 /// "ach_initiated_at": {
2936 /// "description": "The date and time when the transaction was
2937 /// initiated by the Originating Depository Financial Institution (ODFI) in
2938 /// ISO 8601 format without timestamp.",
2939 /// "examples": [
2940 /// "2025-02-13T18:08:00+00:00"
2941 /// ],
2942 /// "type": "string"
2943 /// },
2944 /// "corrected_account_number": {
2945 /// "description": "The account number correction reported by the RDFI.
2946 /// Populate only if the `resolution_code` is `NOTICE_OF_CHANGE`.",
2947 /// "type": "string"
2948 /// },
2949 /// "corrected_routing_number": {
2950 /// "description": "The routing number correction reported by the RDFI.
2951 /// Populate only if the `resolution_code` is `NOTICE_OF_CHANGE`. Must be a
2952 /// valid 9-digit routing number format.",
2953 /// "type": "string"
2954 /// },
2955 /// "id": {
2956 /// "description": "Client-defined identifier for this specific return
2957 /// submission. Allows you to track and reference you requests.",
2958 /// "examples": [
2959 /// "client_ach_id_1234"
2960 /// ],
2961 /// "type": "string"
2962 /// },
2963 /// "member_guid": {
2964 /// "description": "The unique identifier for the member associated
2965 /// with the transaction. Defined by MX.",
2966 /// "examples": [
2967 /// "MBR-7c6f361b-e582-15b6-60c0-358f12466b4b"
2968 /// ],
2969 /// "type": "string"
2970 /// },
2971 /// "return_account_number": {
2972 /// "description": "Incorrect account number used in the ACH
2973 /// transaction.",
2974 /// "type": "string"
2975 /// },
2976 /// "return_code": {
2977 /// "description": "The associated ACH return code and notice of change
2978 /// code (for example, R02, R03, R04, R05, R20, NOC). See [Return
2979 /// Codes](/api-reference/platform-api/reference/ach-return-fields#
2980 /// return-codes) for a complete list.",
2981 /// "examples": [
2982 /// "R01"
2983 /// ],
2984 /// "type": "string"
2985 /// },
2986 /// "return_notes": {
2987 /// "description": "Notes that you set to inform MX on internal ACH
2988 /// processing.",
2989 /// "type": "string"
2990 /// },
2991 /// "return_routing_number": {
2992 /// "description": "Incorrect routing number used in the ACH
2993 /// transaction.",
2994 /// "type": "string"
2995 /// },
2996 /// "returned_at": {
2997 /// "description": "The date and time when the return was reported by
2998 /// the Receiving Financial Depository Institution (RDFI) in ISO 8601 format
2999 /// without timestamp.",
3000 /// "examples": [
3001 /// "2025-02-13T18:09:00+00:00"
3002 /// ],
3003 /// "type": "string"
3004 /// },
3005 /// "sec_code": {
3006 /// "description": "The SEC code (Standard Entry Class Code)–a
3007 /// three-letter code describing how a payment was authorized (for example,
3008 /// `WEB`). See [SEC
3009 /// Codes](/api-reference/platform-api/reference/ach-return-fields#
3010 /// sec-codes) for a complete list.",
3011 /// "examples": [
3012 /// "PPD"
3013 /// ],
3014 /// "type": "string"
3015 /// },
3016 /// "transaction_amount": {
3017 /// "description": "The amount of the transaction.",
3018 /// "examples": [
3019 /// 225.84
3020 /// ],
3021 /// "type": "number"
3022 /// },
3023 /// "transaction_amount_range": {
3024 /// "description": "The transaction amount range, used for impact
3025 /// assessment.",
3026 /// "type": "number"
3027 /// },
3028 /// "user_guid": {
3029 /// "description": "MX-defined identifier for the user associated with
3030 /// the ACH return.",
3031 /// "examples": [
3032 /// "USR-fa7537f3-48aa-a683-a02a-b18940482f54"
3033 /// ],
3034 /// "type": "string"
3035 /// }
3036 /// }
3037 ///}
3038 /// ```
3039 /// </details>
3040 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
3041 pub struct AchReturnCreateRequest {
3042 ///The unique identifier for the account associated with the
3043 /// transaction. Defined by MX.
3044 pub account_guid: ::std::string::String,
3045 ///The last 4 digits of the account number used for the transaction by
3046 /// the Originating Depository Financial Institution (ODFI).
3047 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
3048 pub account_number_last_four: ::std::option::Option<::std::string::String>,
3049 ///The date and time when the transaction was initiated by the
3050 /// Originating Depository Financial Institution (ODFI) in ISO 8601
3051 /// format without timestamp.
3052 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
3053 pub ach_initiated_at: ::std::option::Option<::std::string::String>,
3054 ///The account number correction reported by the RDFI. Populate only if
3055 /// the `resolution_code` is `NOTICE_OF_CHANGE`.
3056 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
3057 pub corrected_account_number: ::std::option::Option<::std::string::String>,
3058 ///The routing number correction reported by the RDFI. Populate only if
3059 /// the `resolution_code` is `NOTICE_OF_CHANGE`. Must be a valid 9-digit
3060 /// routing number format.
3061 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
3062 pub corrected_routing_number: ::std::option::Option<::std::string::String>,
3063 ///Client-defined identifier for this specific return submission.
3064 /// Allows you to track and reference you requests.
3065 pub id: ::std::string::String,
3066 ///The unique identifier for the member associated with the
3067 /// transaction. Defined by MX.
3068 pub member_guid: ::std::string::String,
3069 ///Incorrect account number used in the ACH transaction.
3070 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
3071 pub return_account_number: ::std::option::Option<::std::string::String>,
3072 ///The associated ACH return code and notice of change code (for
3073 /// example, R02, R03, R04, R05, R20, NOC). See [Return
3074 /// Codes](/api-reference/platform-api/reference/ach-return-fields#
3075 /// return-codes) for a complete list.
3076 pub return_code: ::std::string::String,
3077 ///Notes that you set to inform MX on internal ACH processing.
3078 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
3079 pub return_notes: ::std::option::Option<::std::string::String>,
3080 ///Incorrect routing number used in the ACH transaction.
3081 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
3082 pub return_routing_number: ::std::option::Option<::std::string::String>,
3083 ///The date and time when the return was reported by the Receiving
3084 /// Financial Depository Institution (RDFI) in ISO 8601 format without
3085 /// timestamp.
3086 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
3087 pub returned_at: ::std::option::Option<::std::string::String>,
3088 ///The SEC code (Standard Entry Class Code)–a three-letter code
3089 /// describing how a payment was authorized (for example, `WEB`). See
3090 /// [SEC Codes](/api-reference/platform-api/reference/ach-return-fields#
3091 /// sec-codes) for a complete list.
3092 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
3093 pub sec_code: ::std::option::Option<::std::string::String>,
3094 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
3095 pub transaction_amount: ::std::option::Option<f64>,
3096 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
3097 pub transaction_amount_range: ::std::option::Option<f64>,
3098 ///MX-defined identifier for the user associated with the ACH return.
3099 pub user_guid: ::std::string::String,
3100 }
3101
3102 impl ::std::convert::From<&AchReturnCreateRequest> for AchReturnCreateRequest {
3103 fn from(value: &AchReturnCreateRequest) -> Self {
3104 value.clone()
3105 }
3106 }
3107
3108 ///`AchReturnCreateRequestBody`
3109 ///
3110 /// <details><summary>JSON schema</summary>
3111 ///
3112 /// ```json
3113 ///{
3114 /// "type": "object",
3115 /// "properties": {
3116 /// "ach_return": {
3117 /// "$ref": "#/components/schemas/ACHReturnCreateRequest"
3118 /// }
3119 /// }
3120 ///}
3121 /// ```
3122 /// </details>
3123 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
3124 pub struct AchReturnCreateRequestBody {
3125 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
3126 pub ach_return: ::std::option::Option<AchReturnCreateRequest>,
3127 }
3128
3129 impl ::std::convert::From<&AchReturnCreateRequestBody> for AchReturnCreateRequestBody {
3130 fn from(value: &AchReturnCreateRequestBody) -> Self {
3131 value.clone()
3132 }
3133 }
3134
3135 impl ::std::default::Default for AchReturnCreateRequestBody {
3136 fn default() -> Self {
3137 Self {
3138 ach_return: Default::default(),
3139 }
3140 }
3141 }
3142
3143 ///`AchReturnResponseBody`
3144 ///
3145 /// <details><summary>JSON schema</summary>
3146 ///
3147 /// ```json
3148 ///{
3149 /// "type": "object",
3150 /// "properties": {
3151 /// "ach_return": {
3152 /// "$ref": "#/components/schemas/ACHResponse"
3153 /// }
3154 /// }
3155 ///}
3156 /// ```
3157 /// </details>
3158 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
3159 pub struct AchReturnResponseBody {
3160 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
3161 pub ach_return: ::std::option::Option<AchResponse>,
3162 }
3163
3164 impl ::std::convert::From<&AchReturnResponseBody> for AchReturnResponseBody {
3165 fn from(value: &AchReturnResponseBody) -> Self {
3166 value.clone()
3167 }
3168 }
3169
3170 impl ::std::default::Default for AchReturnResponseBody {
3171 fn default() -> Self {
3172 Self {
3173 ach_return: Default::default(),
3174 }
3175 }
3176 }
3177
3178 ///`AchReturnsResponseBody`
3179 ///
3180 /// <details><summary>JSON schema</summary>
3181 ///
3182 /// ```json
3183 ///{
3184 /// "type": "object",
3185 /// "properties": {
3186 /// "ach_returns": {
3187 /// "type": "array",
3188 /// "items": {
3189 /// "$ref": "#/components/schemas/ACHResponse"
3190 /// }
3191 /// },
3192 /// "pagination": {
3193 /// "$ref": "#/components/schemas/PaginationResponse"
3194 /// }
3195 /// }
3196 ///}
3197 /// ```
3198 /// </details>
3199 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
3200 pub struct AchReturnsResponseBody {
3201 #[serde(default, skip_serializing_if = "::std::vec::Vec::is_empty")]
3202 pub ach_returns: ::std::vec::Vec<AchResponse>,
3203 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
3204 pub pagination: ::std::option::Option<PaginationResponse>,
3205 }
3206
3207 impl ::std::convert::From<&AchReturnsResponseBody> for AchReturnsResponseBody {
3208 fn from(value: &AchReturnsResponseBody) -> Self {
3209 value.clone()
3210 }
3211 }
3212
3213 impl ::std::default::Default for AchReturnsResponseBody {
3214 fn default() -> Self {
3215 Self {
3216 ach_returns: Default::default(),
3217 pagination: Default::default(),
3218 }
3219 }
3220 }
3221
3222 ///`AuthorizationCodeRequest`
3223 ///
3224 /// <details><summary>JSON schema</summary>
3225 ///
3226 /// ```json
3227 ///{
3228 /// "type": "object",
3229 /// "properties": {
3230 /// "scope": {
3231 /// "examples": [
3232 /// "user-guid:USR-101ad774-288b-44ed-ad16-da87d522ea20 member-guid:MBR-54feffb9-8474-47bd-8442-de003910113a account-guid:ACT-32a64160-582a-4f00-ab34-5f49cc35ed35 read-protected"
3233 /// ],
3234 /// "type": [
3235 /// "string",
3236 /// "null"
3237 /// ]
3238 /// }
3239 /// }
3240 ///}
3241 /// ```
3242 /// </details>
3243 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
3244 pub struct AuthorizationCodeRequest {
3245 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
3246 pub scope: ::std::option::Option<::std::string::String>,
3247 }
3248
3249 impl ::std::convert::From<&AuthorizationCodeRequest> for AuthorizationCodeRequest {
3250 fn from(value: &AuthorizationCodeRequest) -> Self {
3251 value.clone()
3252 }
3253 }
3254
3255 impl ::std::default::Default for AuthorizationCodeRequest {
3256 fn default() -> Self {
3257 Self {
3258 scope: Default::default(),
3259 }
3260 }
3261 }
3262
3263 ///`AuthorizationCodeRequestBody`
3264 ///
3265 /// <details><summary>JSON schema</summary>
3266 ///
3267 /// ```json
3268 ///{
3269 /// "type": "object",
3270 /// "properties": {
3271 /// "authorization_code": {
3272 /// "$ref": "#/components/schemas/AuthorizationCodeRequest"
3273 /// }
3274 /// }
3275 ///}
3276 /// ```
3277 /// </details>
3278 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
3279 pub struct AuthorizationCodeRequestBody {
3280 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
3281 pub authorization_code: ::std::option::Option<AuthorizationCodeRequest>,
3282 }
3283
3284 impl ::std::convert::From<&AuthorizationCodeRequestBody> for AuthorizationCodeRequestBody {
3285 fn from(value: &AuthorizationCodeRequestBody) -> Self {
3286 value.clone()
3287 }
3288 }
3289
3290 impl ::std::default::Default for AuthorizationCodeRequestBody {
3291 fn default() -> Self {
3292 Self {
3293 authorization_code: Default::default(),
3294 }
3295 }
3296 }
3297
3298 ///`AuthorizationCodeResponse`
3299 ///
3300 /// <details><summary>JSON schema</summary>
3301 ///
3302 /// ```json
3303 ///{
3304 /// "type": "object",
3305 /// "properties": {
3306 /// "code": {
3307 /// "examples": [
3308 /// "9nN-9D8_4Z3WYazx7-zXfmqsD3jwgL_2W927Sb3otI"
3309 /// ],
3310 /// "type": [
3311 /// "string",
3312 /// "null"
3313 /// ]
3314 /// }
3315 /// }
3316 ///}
3317 /// ```
3318 /// </details>
3319 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
3320 pub struct AuthorizationCodeResponse {
3321 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
3322 pub code: ::std::option::Option<::std::string::String>,
3323 }
3324
3325 impl ::std::convert::From<&AuthorizationCodeResponse> for AuthorizationCodeResponse {
3326 fn from(value: &AuthorizationCodeResponse) -> Self {
3327 value.clone()
3328 }
3329 }
3330
3331 impl ::std::default::Default for AuthorizationCodeResponse {
3332 fn default() -> Self {
3333 Self {
3334 code: Default::default(),
3335 }
3336 }
3337 }
3338
3339 ///`AuthorizationCodeResponseBody`
3340 ///
3341 /// <details><summary>JSON schema</summary>
3342 ///
3343 /// ```json
3344 ///{
3345 /// "type": "object",
3346 /// "properties": {
3347 /// "authorization_code": {
3348 /// "$ref": "#/components/schemas/AuthorizationCodeResponse"
3349 /// }
3350 /// }
3351 ///}
3352 /// ```
3353 /// </details>
3354 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
3355 pub struct AuthorizationCodeResponseBody {
3356 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
3357 pub authorization_code: ::std::option::Option<AuthorizationCodeResponse>,
3358 }
3359
3360 impl ::std::convert::From<&AuthorizationCodeResponseBody> for AuthorizationCodeResponseBody {
3361 fn from(value: &AuthorizationCodeResponseBody) -> Self {
3362 value.clone()
3363 }
3364 }
3365
3366 impl ::std::default::Default for AuthorizationCodeResponseBody {
3367 fn default() -> Self {
3368 Self {
3369 authorization_code: Default::default(),
3370 }
3371 }
3372 }
3373
3374 ///`BudgetCreateRequest`
3375 ///
3376 /// <details><summary>JSON schema</summary>
3377 ///
3378 /// ```json
3379 ///{
3380 /// "type": "object",
3381 /// "required": [
3382 /// "category_guid",
3383 /// "parent_guid"
3384 /// ],
3385 /// "properties": {
3386 /// "amount": {
3387 /// "description": "Amount of the budget.",
3388 /// "examples": [
3389 /// 1000
3390 /// ],
3391 /// "type": "integer"
3392 /// },
3393 /// "category_guid": {
3394 /// "description": "Unique identifier of the category.",
3395 /// "examples": [
3396 /// "CAT-bd56d35a-a9a7-6e10-66c1-5b9cc1b6c81a"
3397 /// ],
3398 /// "type": "string"
3399 /// },
3400 /// "metadata": {
3401 /// "description": "Additional information a partner can store on the
3402 /// budget.",
3403 /// "examples": [
3404 /// "Additional information"
3405 /// ],
3406 /// "type": "string"
3407 /// },
3408 /// "parent_guid": {
3409 /// "description": "Unique identifier of the parent budget. This is
3410 /// only required when creating a budget on a sub-category.",
3411 /// "examples": [
3412 /// "BGT-6be44a91-e105-f68a-4770-8c7c0a5c9778"
3413 /// ],
3414 /// "type": "string"
3415 /// },
3416 /// "skip_webhook": {
3417 /// "description": "When set to true, this parameter will prevent a
3418 /// webhook from being triggered by the request.",
3419 /// "examples": [
3420 /// true
3421 /// ],
3422 /// "type": "boolean"
3423 /// }
3424 /// }
3425 ///}
3426 /// ```
3427 /// </details>
3428 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
3429 pub struct BudgetCreateRequest {
3430 ///Amount of the budget.
3431 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
3432 pub amount: ::std::option::Option<i64>,
3433 ///Unique identifier of the category.
3434 pub category_guid: ::std::string::String,
3435 ///Additional information a partner can store on the budget.
3436 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
3437 pub metadata: ::std::option::Option<::std::string::String>,
3438 ///Unique identifier of the parent budget. This is only required when
3439 /// creating a budget on a sub-category.
3440 pub parent_guid: ::std::string::String,
3441 ///When set to true, this parameter will prevent a webhook from being
3442 /// triggered by the request.
3443 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
3444 pub skip_webhook: ::std::option::Option<bool>,
3445 }
3446
3447 impl ::std::convert::From<&BudgetCreateRequest> for BudgetCreateRequest {
3448 fn from(value: &BudgetCreateRequest) -> Self {
3449 value.clone()
3450 }
3451 }
3452
3453 ///`BudgetCreateRequestBody`
3454 ///
3455 /// <details><summary>JSON schema</summary>
3456 ///
3457 /// ```json
3458 ///{
3459 /// "type": "object",
3460 /// "properties": {
3461 /// "budget": {
3462 /// "$ref": "#/components/schemas/BudgetCreateRequest"
3463 /// }
3464 /// }
3465 ///}
3466 /// ```
3467 /// </details>
3468 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
3469 pub struct BudgetCreateRequestBody {
3470 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
3471 pub budget: ::std::option::Option<BudgetCreateRequest>,
3472 }
3473
3474 impl ::std::convert::From<&BudgetCreateRequestBody> for BudgetCreateRequestBody {
3475 fn from(value: &BudgetCreateRequestBody) -> Self {
3476 value.clone()
3477 }
3478 }
3479
3480 impl ::std::default::Default for BudgetCreateRequestBody {
3481 fn default() -> Self {
3482 Self {
3483 budget: Default::default(),
3484 }
3485 }
3486 }
3487
3488 ///`BudgetResponse`
3489 ///
3490 /// <details><summary>JSON schema</summary>
3491 ///
3492 /// ```json
3493 ///{
3494 /// "properties": {
3495 /// "amount": {
3496 /// "description": "A goal amount set by the user for a category's
3497 /// transaction total during a month.",
3498 /// "examples": [
3499 /// 153
3500 /// ],
3501 /// "type": "number"
3502 /// },
3503 /// "category_guid": {
3504 /// "description": "Unique identifier for the budget category. Defined
3505 /// by MX.",
3506 /// "examples": [
3507 /// "CAT-bd56d35a-a9a7-6e10-66c1-5b9cc1b6c81a"
3508 /// ],
3509 /// "type": "string"
3510 /// },
3511 /// "created_at": {
3512 /// "description": "Date and time the budget was created, represented
3513 /// in ISO 8601 format with timestamp.",
3514 /// "examples": [
3515 /// "2018-10-18T19:51:26+00:00"
3516 /// ],
3517 /// "type": "string"
3518 /// },
3519 /// "guid": {
3520 /// "description": "Unique identifier for the budget. Defined by MX.",
3521 /// "examples": [
3522 /// "BGT-6ca0e3ef-c65e-4655-8b5a-275a3c19c21d"
3523 /// ],
3524 /// "type": "string"
3525 /// },
3526 /// "is_exceeded": {
3527 /// "description": "If the budget has been exceeded, this field will be
3528 /// true. Otherwise, this field will be false.",
3529 /// "examples": [
3530 /// true
3531 /// ],
3532 /// "type": "boolean"
3533 /// },
3534 /// "is_off_track": {
3535 /// "description": "If the budget is off track, this field will be
3536 /// true. Otherwise, this field will be false.",
3537 /// "examples": [
3538 /// true
3539 /// ],
3540 /// "type": "boolean"
3541 /// },
3542 /// "metadata": {
3543 /// "description": "Additional information a partner can store on the
3544 /// budget.",
3545 /// "examples": [
3546 /// "some metadata"
3547 /// ],
3548 /// "type": [
3549 /// "string",
3550 /// "null"
3551 /// ]
3552 /// },
3553 /// "name": {
3554 /// "description": "The name of the budget that is visible to the user
3555 /// (ie \"Food\", \"Bills\", \"Entertainment\", etc).",
3556 /// "examples": [
3557 /// "Food & Dining"
3558 /// ],
3559 /// "type": [
3560 /// "string",
3561 /// "null"
3562 /// ]
3563 /// },
3564 /// "off_track_percentage": {
3565 /// "description": "The percentage amount of off track spending.
3566 /// (Deprecated).",
3567 /// "type": [
3568 /// "number",
3569 /// "null"
3570 /// ]
3571 /// },
3572 /// "parent_guid": {
3573 /// "description": "Unique identifier for the parent budget. Defined by
3574 /// MX.",
3575 /// "type": [
3576 /// "string",
3577 /// "null"
3578 /// ]
3579 /// },
3580 /// "percent_spent": {
3581 /// "description": "The percentage of a budget that has been spent
3582 /// during the current calendar month Calculated as the transaction total
3583 /// divided by the amount and then multiplied by 100.A value of zero will be
3584 /// returned when `amount` is zero.",
3585 /// "examples": [
3586 /// 1276.34
3587 /// ],
3588 /// "type": [
3589 /// "number",
3590 /// "null"
3591 /// ]
3592 /// },
3593 /// "projected_spending": {
3594 /// "description": "The projected amount of spending for the budget.",
3595 /// "examples": [
3596 /// 3562.4
3597 /// ],
3598 /// "type": "number"
3599 /// },
3600 /// "revision": {
3601 /// "description": "The revision number of this budget record.",
3602 /// "examples": [
3603 /// 561
3604 /// ],
3605 /// "type": "integer"
3606 /// },
3607 /// "transaction_total": {
3608 /// "description": "The cumulative amount of all transactions under the
3609 /// budget.",
3610 /// "examples": [
3611 /// 1952.8
3612 /// ]
3613 /// },
3614 /// "updated_at": {
3615 /// "description": "Date and time the budget was updated, represented
3616 /// in ISO 8601 format with timestamp.",
3617 /// "examples": [
3618 /// "2022-06-14T21:17:11+00:00"
3619 /// ]
3620 /// },
3621 /// "user_guid": {
3622 /// "description": "Unique identifier for the user. Defined by MX.",
3623 /// "examples": [
3624 /// "USR-11141024-90b3-1bce-cac9-c06ced52ab4c"
3625 /// ]
3626 /// }
3627 /// }
3628 ///}
3629 /// ```
3630 /// </details>
3631 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
3632 pub struct BudgetResponse {
3633 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
3634 pub amount: ::std::option::Option<f64>,
3635 ///Unique identifier for the budget category. Defined by MX.
3636 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
3637 pub category_guid: ::std::option::Option<::std::string::String>,
3638 ///Date and time the budget was created, represented in ISO 8601 format
3639 /// with timestamp.
3640 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
3641 pub created_at: ::std::option::Option<::std::string::String>,
3642 ///Unique identifier for the budget. Defined by MX.
3643 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
3644 pub guid: ::std::option::Option<::std::string::String>,
3645 ///If the budget has been exceeded, this field will be true. Otherwise,
3646 /// this field will be false.
3647 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
3648 pub is_exceeded: ::std::option::Option<bool>,
3649 ///If the budget is off track, this field will be true. Otherwise, this
3650 /// field will be false.
3651 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
3652 pub is_off_track: ::std::option::Option<bool>,
3653 ///Additional information a partner can store on the budget.
3654 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
3655 pub metadata: ::std::option::Option<::std::string::String>,
3656 ///The name of the budget that is visible to the user (ie "Food",
3657 /// "Bills", "Entertainment", etc).
3658 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
3659 pub name: ::std::option::Option<::std::string::String>,
3660 ///The percentage amount of off track spending. (Deprecated).
3661 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
3662 pub off_track_percentage: ::std::option::Option<f64>,
3663 ///Unique identifier for the parent budget. Defined by MX.
3664 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
3665 pub parent_guid: ::std::option::Option<::std::string::String>,
3666 ///The percentage of a budget that has been spent during the current
3667 /// calendar month Calculated as the transaction total divided by the
3668 /// amount and then multiplied by 100.A value of zero will be returned
3669 /// when `amount` is zero.
3670 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
3671 pub percent_spent: ::std::option::Option<f64>,
3672 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
3673 pub projected_spending: ::std::option::Option<f64>,
3674 ///The revision number of this budget record.
3675 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
3676 pub revision: ::std::option::Option<i64>,
3677 ///The cumulative amount of all transactions under the budget.
3678 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
3679 pub transaction_total: ::std::option::Option<::serde_json::Value>,
3680 ///Date and time the budget was updated, represented in ISO 8601 format
3681 /// with timestamp.
3682 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
3683 pub updated_at: ::std::option::Option<::serde_json::Value>,
3684 ///Unique identifier for the user. Defined by MX.
3685 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
3686 pub user_guid: ::std::option::Option<::serde_json::Value>,
3687 }
3688
3689 impl ::std::convert::From<&BudgetResponse> for BudgetResponse {
3690 fn from(value: &BudgetResponse) -> Self {
3691 value.clone()
3692 }
3693 }
3694
3695 impl ::std::default::Default for BudgetResponse {
3696 fn default() -> Self {
3697 Self {
3698 amount: Default::default(),
3699 category_guid: Default::default(),
3700 created_at: Default::default(),
3701 guid: Default::default(),
3702 is_exceeded: Default::default(),
3703 is_off_track: Default::default(),
3704 metadata: Default::default(),
3705 name: Default::default(),
3706 off_track_percentage: Default::default(),
3707 parent_guid: Default::default(),
3708 percent_spent: Default::default(),
3709 projected_spending: Default::default(),
3710 revision: Default::default(),
3711 transaction_total: Default::default(),
3712 updated_at: Default::default(),
3713 user_guid: Default::default(),
3714 }
3715 }
3716 }
3717
3718 ///`BudgetResponseBody`
3719 ///
3720 /// <details><summary>JSON schema</summary>
3721 ///
3722 /// ```json
3723 ///{
3724 /// "type": "object",
3725 /// "properties": {
3726 /// "budget": {
3727 /// "$ref": "#/components/schemas/BudgetResponse"
3728 /// }
3729 /// }
3730 ///}
3731 /// ```
3732 /// </details>
3733 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
3734 pub struct BudgetResponseBody {
3735 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
3736 pub budget: ::std::option::Option<BudgetResponse>,
3737 }
3738
3739 impl ::std::convert::From<&BudgetResponseBody> for BudgetResponseBody {
3740 fn from(value: &BudgetResponseBody) -> Self {
3741 value.clone()
3742 }
3743 }
3744
3745 impl ::std::default::Default for BudgetResponseBody {
3746 fn default() -> Self {
3747 Self {
3748 budget: Default::default(),
3749 }
3750 }
3751 }
3752
3753 ///`BudgetUpdateRequest`
3754 ///
3755 /// <details><summary>JSON schema</summary>
3756 ///
3757 /// ```json
3758 ///{
3759 /// "type": "object",
3760 /// "properties": {
3761 /// "amount": {
3762 /// "description": "Amount of the budget.",
3763 /// "examples": [
3764 /// 1000
3765 /// ],
3766 /// "type": "integer"
3767 /// },
3768 /// "metadata": {
3769 /// "description": "Additional information a partner can store on the
3770 /// budget.",
3771 /// "examples": [
3772 /// "Additional information"
3773 /// ],
3774 /// "type": "string"
3775 /// },
3776 /// "skip_webhook": {
3777 /// "description": "When set to true, this parameter will prevent a
3778 /// webhook from being triggered by the request.",
3779 /// "examples": [
3780 /// true
3781 /// ],
3782 /// "type": "boolean"
3783 /// }
3784 /// }
3785 ///}
3786 /// ```
3787 /// </details>
3788 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
3789 pub struct BudgetUpdateRequest {
3790 ///Amount of the budget.
3791 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
3792 pub amount: ::std::option::Option<i64>,
3793 ///Additional information a partner can store on the budget.
3794 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
3795 pub metadata: ::std::option::Option<::std::string::String>,
3796 ///When set to true, this parameter will prevent a webhook from being
3797 /// triggered by the request.
3798 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
3799 pub skip_webhook: ::std::option::Option<bool>,
3800 }
3801
3802 impl ::std::convert::From<&BudgetUpdateRequest> for BudgetUpdateRequest {
3803 fn from(value: &BudgetUpdateRequest) -> Self {
3804 value.clone()
3805 }
3806 }
3807
3808 impl ::std::default::Default for BudgetUpdateRequest {
3809 fn default() -> Self {
3810 Self {
3811 amount: Default::default(),
3812 metadata: Default::default(),
3813 skip_webhook: Default::default(),
3814 }
3815 }
3816 }
3817
3818 ///`BudgetUpdateRequestBody`
3819 ///
3820 /// <details><summary>JSON schema</summary>
3821 ///
3822 /// ```json
3823 ///{
3824 /// "type": "object",
3825 /// "properties": {
3826 /// "budget": {
3827 /// "$ref": "#/components/schemas/BudgetUpdateRequest"
3828 /// }
3829 /// }
3830 ///}
3831 /// ```
3832 /// </details>
3833 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
3834 pub struct BudgetUpdateRequestBody {
3835 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
3836 pub budget: ::std::option::Option<BudgetUpdateRequest>,
3837 }
3838
3839 impl ::std::convert::From<&BudgetUpdateRequestBody> for BudgetUpdateRequestBody {
3840 fn from(value: &BudgetUpdateRequestBody) -> Self {
3841 value.clone()
3842 }
3843 }
3844
3845 impl ::std::default::Default for BudgetUpdateRequestBody {
3846 fn default() -> Self {
3847 Self {
3848 budget: Default::default(),
3849 }
3850 }
3851 }
3852
3853 ///`CategoriesResponseBody`
3854 ///
3855 /// <details><summary>JSON schema</summary>
3856 ///
3857 /// ```json
3858 ///{
3859 /// "type": "object",
3860 /// "properties": {
3861 /// "categories": {
3862 /// "type": "array",
3863 /// "items": {
3864 /// "$ref": "#/components/schemas/CategoryResponse"
3865 /// }
3866 /// },
3867 /// "pagination": {
3868 /// "$ref": "#/components/schemas/PaginationResponse"
3869 /// }
3870 /// }
3871 ///}
3872 /// ```
3873 /// </details>
3874 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
3875 pub struct CategoriesResponseBody {
3876 #[serde(default, skip_serializing_if = "::std::vec::Vec::is_empty")]
3877 pub categories: ::std::vec::Vec<CategoryResponse>,
3878 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
3879 pub pagination: ::std::option::Option<PaginationResponse>,
3880 }
3881
3882 impl ::std::convert::From<&CategoriesResponseBody> for CategoriesResponseBody {
3883 fn from(value: &CategoriesResponseBody) -> Self {
3884 value.clone()
3885 }
3886 }
3887
3888 impl ::std::default::Default for CategoriesResponseBody {
3889 fn default() -> Self {
3890 Self {
3891 categories: Default::default(),
3892 pagination: Default::default(),
3893 }
3894 }
3895 }
3896
3897 ///`CategoryCreateRequest`
3898 ///
3899 /// <details><summary>JSON schema</summary>
3900 ///
3901 /// ```json
3902 ///{
3903 /// "type": "object",
3904 /// "required": [
3905 /// "name",
3906 /// "parent_guid"
3907 /// ],
3908 /// "properties": {
3909 /// "metadata": {
3910 /// "examples": [
3911 /// "some metadata"
3912 /// ],
3913 /// "type": "string"
3914 /// },
3915 /// "name": {
3916 /// "examples": [
3917 /// "Online Shopping"
3918 /// ],
3919 /// "type": "string"
3920 /// },
3921 /// "parent_guid": {
3922 /// "examples": [
3923 /// "CAT-aad51b46-d6f7-3da5-fd6e-492328b3023f"
3924 /// ],
3925 /// "type": "string"
3926 /// }
3927 /// }
3928 ///}
3929 /// ```
3930 /// </details>
3931 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
3932 pub struct CategoryCreateRequest {
3933 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
3934 pub metadata: ::std::option::Option<::std::string::String>,
3935 pub name: ::std::string::String,
3936 pub parent_guid: ::std::string::String,
3937 }
3938
3939 impl ::std::convert::From<&CategoryCreateRequest> for CategoryCreateRequest {
3940 fn from(value: &CategoryCreateRequest) -> Self {
3941 value.clone()
3942 }
3943 }
3944
3945 ///`CategoryCreateRequestBody`
3946 ///
3947 /// <details><summary>JSON schema</summary>
3948 ///
3949 /// ```json
3950 ///{
3951 /// "type": "object",
3952 /// "properties": {
3953 /// "category": {
3954 /// "$ref": "#/components/schemas/CategoryCreateRequest"
3955 /// }
3956 /// }
3957 ///}
3958 /// ```
3959 /// </details>
3960 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
3961 pub struct CategoryCreateRequestBody {
3962 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
3963 pub category: ::std::option::Option<CategoryCreateRequest>,
3964 }
3965
3966 impl ::std::convert::From<&CategoryCreateRequestBody> for CategoryCreateRequestBody {
3967 fn from(value: &CategoryCreateRequestBody) -> Self {
3968 value.clone()
3969 }
3970 }
3971
3972 impl ::std::default::Default for CategoryCreateRequestBody {
3973 fn default() -> Self {
3974 Self {
3975 category: Default::default(),
3976 }
3977 }
3978 }
3979
3980 ///`CategoryResponse`
3981 ///
3982 /// <details><summary>JSON schema</summary>
3983 ///
3984 /// ```json
3985 ///{
3986 /// "type": "object",
3987 /// "properties": {
3988 /// "created_at": {
3989 /// "description": "Category creation date-time.",
3990 /// "examples": [
3991 /// "2015-04-13T18:01:23.000Z"
3992 /// ],
3993 /// "type": [
3994 /// "string",
3995 /// "null"
3996 /// ]
3997 /// },
3998 /// "guid": {
3999 /// "examples": [
4000 /// "CAT-7829f71c-2e8c-afa5-2f55-fa3634b89874"
4001 /// ],
4002 /// "type": [
4003 /// "string",
4004 /// "null"
4005 /// ]
4006 /// },
4007 /// "is_default": {
4008 /// "examples": [
4009 /// true
4010 /// ],
4011 /// "type": [
4012 /// "boolean",
4013 /// "null"
4014 /// ]
4015 /// },
4016 /// "is_income": {
4017 /// "examples": [
4018 /// false
4019 /// ],
4020 /// "type": [
4021 /// "boolean",
4022 /// "null"
4023 /// ]
4024 /// },
4025 /// "metadata": {
4026 /// "examples": [
4027 /// "some metadata"
4028 /// ],
4029 /// "type": [
4030 /// "string",
4031 /// "null"
4032 /// ]
4033 /// },
4034 /// "name": {
4035 /// "examples": [
4036 /// "Auto Insurance"
4037 /// ],
4038 /// "type": [
4039 /// "string",
4040 /// "null"
4041 /// ]
4042 /// },
4043 /// "parent_guid": {
4044 /// "examples": [
4045 /// "CAT-7829f71c-2e8c-afa5-2f55-fa3634b89874"
4046 /// ],
4047 /// "type": [
4048 /// "string",
4049 /// "null"
4050 /// ]
4051 /// },
4052 /// "updated_at": {
4053 /// "examples": [
4054 /// "2015-05-13T18:01:23.000Z"
4055 /// ],
4056 /// "type": [
4057 /// "string",
4058 /// "null"
4059 /// ]
4060 /// }
4061 /// }
4062 ///}
4063 /// ```
4064 /// </details>
4065 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
4066 pub struct CategoryResponse {
4067 ///Category creation date-time.
4068 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
4069 pub created_at: ::std::option::Option<::std::string::String>,
4070 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
4071 pub guid: ::std::option::Option<::std::string::String>,
4072 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
4073 pub is_default: ::std::option::Option<bool>,
4074 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
4075 pub is_income: ::std::option::Option<bool>,
4076 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
4077 pub metadata: ::std::option::Option<::std::string::String>,
4078 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
4079 pub name: ::std::option::Option<::std::string::String>,
4080 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
4081 pub parent_guid: ::std::option::Option<::std::string::String>,
4082 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
4083 pub updated_at: ::std::option::Option<::std::string::String>,
4084 }
4085
4086 impl ::std::convert::From<&CategoryResponse> for CategoryResponse {
4087 fn from(value: &CategoryResponse) -> Self {
4088 value.clone()
4089 }
4090 }
4091
4092 impl ::std::default::Default for CategoryResponse {
4093 fn default() -> Self {
4094 Self {
4095 created_at: Default::default(),
4096 guid: Default::default(),
4097 is_default: Default::default(),
4098 is_income: Default::default(),
4099 metadata: Default::default(),
4100 name: Default::default(),
4101 parent_guid: Default::default(),
4102 updated_at: Default::default(),
4103 }
4104 }
4105 }
4106
4107 ///`CategoryResponseBody`
4108 ///
4109 /// <details><summary>JSON schema</summary>
4110 ///
4111 /// ```json
4112 ///{
4113 /// "type": "object",
4114 /// "properties": {
4115 /// "category": {
4116 /// "$ref": "#/components/schemas/CategoryResponse"
4117 /// }
4118 /// }
4119 ///}
4120 /// ```
4121 /// </details>
4122 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
4123 pub struct CategoryResponseBody {
4124 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
4125 pub category: ::std::option::Option<CategoryResponse>,
4126 }
4127
4128 impl ::std::convert::From<&CategoryResponseBody> for CategoryResponseBody {
4129 fn from(value: &CategoryResponseBody) -> Self {
4130 value.clone()
4131 }
4132 }
4133
4134 impl ::std::default::Default for CategoryResponseBody {
4135 fn default() -> Self {
4136 Self {
4137 category: Default::default(),
4138 }
4139 }
4140 }
4141
4142 ///`CategoryUpdateRequest`
4143 ///
4144 /// <details><summary>JSON schema</summary>
4145 ///
4146 /// ```json
4147 ///{
4148 /// "type": "object",
4149 /// "properties": {
4150 /// "metadata": {
4151 /// "examples": [
4152 /// "some metadata"
4153 /// ],
4154 /// "type": "string"
4155 /// },
4156 /// "name": {
4157 /// "examples": [
4158 /// "Web shopping"
4159 /// ],
4160 /// "type": "string"
4161 /// }
4162 /// }
4163 ///}
4164 /// ```
4165 /// </details>
4166 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
4167 pub struct CategoryUpdateRequest {
4168 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
4169 pub metadata: ::std::option::Option<::std::string::String>,
4170 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
4171 pub name: ::std::option::Option<::std::string::String>,
4172 }
4173
4174 impl ::std::convert::From<&CategoryUpdateRequest> for CategoryUpdateRequest {
4175 fn from(value: &CategoryUpdateRequest) -> Self {
4176 value.clone()
4177 }
4178 }
4179
4180 impl ::std::default::Default for CategoryUpdateRequest {
4181 fn default() -> Self {
4182 Self {
4183 metadata: Default::default(),
4184 name: Default::default(),
4185 }
4186 }
4187 }
4188
4189 ///`CategoryUpdateRequestBody`
4190 ///
4191 /// <details><summary>JSON schema</summary>
4192 ///
4193 /// ```json
4194 ///{
4195 /// "type": "object",
4196 /// "properties": {
4197 /// "category": {
4198 /// "$ref": "#/components/schemas/CategoryUpdateRequest"
4199 /// }
4200 /// }
4201 ///}
4202 /// ```
4203 /// </details>
4204 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
4205 pub struct CategoryUpdateRequestBody {
4206 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
4207 pub category: ::std::option::Option<CategoryUpdateRequest>,
4208 }
4209
4210 impl ::std::convert::From<&CategoryUpdateRequestBody> for CategoryUpdateRequestBody {
4211 fn from(value: &CategoryUpdateRequestBody) -> Self {
4212 value.clone()
4213 }
4214 }
4215
4216 impl ::std::default::Default for CategoryUpdateRequestBody {
4217 fn default() -> Self {
4218 Self {
4219 category: Default::default(),
4220 }
4221 }
4222 }
4223
4224 ///`ChallengeResponse`
4225 ///
4226 /// <details><summary>JSON schema</summary>
4227 ///
4228 /// ```json
4229 ///{
4230 /// "type": "object",
4231 /// "properties": {
4232 /// "field_name": {
4233 /// "examples": [
4234 /// "Who is this guy?"
4235 /// ],
4236 /// "type": [
4237 /// "string",
4238 /// "null"
4239 /// ]
4240 /// },
4241 /// "guid": {
4242 /// "examples": [
4243 /// "CRD-ce76d2e3-86bd-ec4a-ec52-eb53b5194bf5"
4244 /// ],
4245 /// "type": [
4246 /// "string",
4247 /// "null"
4248 /// ]
4249 /// },
4250 /// "image_data": {
4251 /// "examples": [
4252 /// "Who is this guy?"
4253 /// ],
4254 /// "type": [
4255 /// "string",
4256 /// "null"
4257 /// ]
4258 /// },
4259 /// "image_options": {
4260 /// "type": "array",
4261 /// "items": {
4262 /// "$ref": "#/components/schemas/ImageOptionResponse"
4263 /// }
4264 /// },
4265 /// "label": {
4266 /// "examples": [
4267 /// "Who is this guy?"
4268 /// ],
4269 /// "type": [
4270 /// "string",
4271 /// "null"
4272 /// ]
4273 /// },
4274 /// "options": {
4275 /// "type": "array",
4276 /// "items": {
4277 /// "$ref": "#/components/schemas/OptionResponse"
4278 /// }
4279 /// },
4280 /// "type": {
4281 /// "examples": [
4282 /// "IMAGE_DATA"
4283 /// ],
4284 /// "type": [
4285 /// "string",
4286 /// "null"
4287 /// ]
4288 /// }
4289 /// }
4290 ///}
4291 /// ```
4292 /// </details>
4293 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
4294 pub struct ChallengeResponse {
4295 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
4296 pub field_name: ::std::option::Option<::std::string::String>,
4297 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
4298 pub guid: ::std::option::Option<::std::string::String>,
4299 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
4300 pub image_data: ::std::option::Option<::std::string::String>,
4301 #[serde(default, skip_serializing_if = "::std::vec::Vec::is_empty")]
4302 pub image_options: ::std::vec::Vec<ImageOptionResponse>,
4303 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
4304 pub label: ::std::option::Option<::std::string::String>,
4305 #[serde(default, skip_serializing_if = "::std::vec::Vec::is_empty")]
4306 pub options: ::std::vec::Vec<OptionResponse>,
4307 #[serde(
4308 rename = "type",
4309 default,
4310 skip_serializing_if = "::std::option::Option::is_none"
4311 )]
4312 pub type_: ::std::option::Option<::std::string::String>,
4313 }
4314
4315 impl ::std::convert::From<&ChallengeResponse> for ChallengeResponse {
4316 fn from(value: &ChallengeResponse) -> Self {
4317 value.clone()
4318 }
4319 }
4320
4321 impl ::std::default::Default for ChallengeResponse {
4322 fn default() -> Self {
4323 Self {
4324 field_name: Default::default(),
4325 guid: Default::default(),
4326 image_data: Default::default(),
4327 image_options: Default::default(),
4328 label: Default::default(),
4329 options: Default::default(),
4330 type_: Default::default(),
4331 }
4332 }
4333 }
4334
4335 ///`ChallengesResponseBody`
4336 ///
4337 /// <details><summary>JSON schema</summary>
4338 ///
4339 /// ```json
4340 ///{
4341 /// "type": "object",
4342 /// "properties": {
4343 /// "challenges": {
4344 /// "type": "array",
4345 /// "items": {
4346 /// "$ref": "#/components/schemas/ChallengeResponse"
4347 /// }
4348 /// },
4349 /// "pagination": {
4350 /// "$ref": "#/components/schemas/PaginationResponse"
4351 /// }
4352 /// }
4353 ///}
4354 /// ```
4355 /// </details>
4356 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
4357 pub struct ChallengesResponseBody {
4358 #[serde(default, skip_serializing_if = "::std::vec::Vec::is_empty")]
4359 pub challenges: ::std::vec::Vec<ChallengeResponse>,
4360 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
4361 pub pagination: ::std::option::Option<PaginationResponse>,
4362 }
4363
4364 impl ::std::convert::From<&ChallengesResponseBody> for ChallengesResponseBody {
4365 fn from(value: &ChallengesResponseBody) -> Self {
4366 value.clone()
4367 }
4368 }
4369
4370 impl ::std::default::Default for ChallengesResponseBody {
4371 fn default() -> Self {
4372 Self {
4373 challenges: Default::default(),
4374 pagination: Default::default(),
4375 }
4376 }
4377 }
4378
4379 ///`ConnectWidgetRequest`
4380 ///
4381 /// <details><summary>JSON schema</summary>
4382 ///
4383 /// ```json
4384 ///{
4385 /// "type": "object",
4386 /// "properties": {
4387 /// "client_redirect_url": {
4388 /// "examples": [
4389 /// "https://{yoursite.com}"
4390 /// ],
4391 /// "type": "string"
4392 /// },
4393 /// "color_scheme": {
4394 /// "examples": [
4395 /// "light"
4396 /// ],
4397 /// "type": "string"
4398 /// },
4399 /// "current_institution_code": {
4400 /// "examples": [
4401 /// "mxbank"
4402 /// ],
4403 /// "type": "string"
4404 /// },
4405 /// "current_member_guid": {
4406 /// "examples": [
4407 /// "MBR-7c6f361b-e582-15b6-60c0-358f12466b4b"
4408 /// ],
4409 /// "type": "string"
4410 /// },
4411 /// "disable_background_agg": {
4412 /// "examples": [
4413 /// false
4414 /// ],
4415 /// "type": "boolean"
4416 /// },
4417 /// "disable_institution_search": {
4418 /// "examples": [
4419 /// false
4420 /// ],
4421 /// "type": "boolean"
4422 /// },
4423 /// "enable_app2app": {
4424 /// "description": "This indicates whether OAuth app2app behavior is
4425 /// enabled for institutions that support it. Defaults to `true`. When set
4426 /// to `false`, the widget will **not** direct the end user to the
4427 /// institution's mobile application. This setting is not persistent. This
4428 /// setting currently only affects Chase institutions.\n",
4429 /// "examples": [
4430 /// false
4431 /// ],
4432 /// "type": "boolean"
4433 /// },
4434 /// "include_identity": {
4435 /// "examples": [
4436 /// false
4437 /// ],
4438 /// "type": "boolean"
4439 /// },
4440 /// "include_transactions": {
4441 /// "examples": [
4442 /// true
4443 /// ],
4444 /// "type": "boolean"
4445 /// },
4446 /// "is_mobile_webview": {
4447 /// "examples": [
4448 /// false
4449 /// ],
4450 /// "type": "boolean"
4451 /// },
4452 /// "mode": {
4453 /// "examples": [
4454 /// "aggregation"
4455 /// ],
4456 /// "type": "string"
4457 /// },
4458 /// "oauth_referral_source": {
4459 /// "examples": [
4460 /// "BROWSER"
4461 /// ],
4462 /// "type": "string"
4463 /// },
4464 /// "ui_message_version": {
4465 /// "examples": [
4466 /// 4
4467 /// ],
4468 /// "type": "integer"
4469 /// },
4470 /// "ui_message_webview_url_scheme": {
4471 /// "type": "string"
4472 /// },
4473 /// "update_credentials": {
4474 /// "examples": [
4475 /// false
4476 /// ],
4477 /// "type": "boolean"
4478 /// }
4479 /// }
4480 ///}
4481 /// ```
4482 /// </details>
4483 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
4484 pub struct ConnectWidgetRequest {
4485 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
4486 pub client_redirect_url: ::std::option::Option<::std::string::String>,
4487 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
4488 pub color_scheme: ::std::option::Option<::std::string::String>,
4489 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
4490 pub current_institution_code: ::std::option::Option<::std::string::String>,
4491 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
4492 pub current_member_guid: ::std::option::Option<::std::string::String>,
4493 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
4494 pub disable_background_agg: ::std::option::Option<bool>,
4495 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
4496 pub disable_institution_search: ::std::option::Option<bool>,
4497 ///This indicates whether OAuth app2app behavior is enabled for
4498 /// institutions that support it. Defaults to `true`. When set to
4499 /// `false`, the widget will **not** direct the end user to the
4500 /// institution's mobile application. This setting is not persistent.
4501 /// This setting currently only affects Chase institutions.
4502 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
4503 pub enable_app2app: ::std::option::Option<bool>,
4504 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
4505 pub include_identity: ::std::option::Option<bool>,
4506 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
4507 pub include_transactions: ::std::option::Option<bool>,
4508 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
4509 pub is_mobile_webview: ::std::option::Option<bool>,
4510 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
4511 pub mode: ::std::option::Option<::std::string::String>,
4512 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
4513 pub oauth_referral_source: ::std::option::Option<::std::string::String>,
4514 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
4515 pub ui_message_version: ::std::option::Option<i64>,
4516 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
4517 pub ui_message_webview_url_scheme: ::std::option::Option<::std::string::String>,
4518 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
4519 pub update_credentials: ::std::option::Option<bool>,
4520 }
4521
4522 impl ::std::convert::From<&ConnectWidgetRequest> for ConnectWidgetRequest {
4523 fn from(value: &ConnectWidgetRequest) -> Self {
4524 value.clone()
4525 }
4526 }
4527
4528 impl ::std::default::Default for ConnectWidgetRequest {
4529 fn default() -> Self {
4530 Self {
4531 client_redirect_url: Default::default(),
4532 color_scheme: Default::default(),
4533 current_institution_code: Default::default(),
4534 current_member_guid: Default::default(),
4535 disable_background_agg: Default::default(),
4536 disable_institution_search: Default::default(),
4537 enable_app2app: Default::default(),
4538 include_identity: Default::default(),
4539 include_transactions: Default::default(),
4540 is_mobile_webview: Default::default(),
4541 mode: Default::default(),
4542 oauth_referral_source: Default::default(),
4543 ui_message_version: Default::default(),
4544 ui_message_webview_url_scheme: Default::default(),
4545 update_credentials: Default::default(),
4546 }
4547 }
4548 }
4549
4550 ///`ConnectWidgetRequestBody`
4551 ///
4552 /// <details><summary>JSON schema</summary>
4553 ///
4554 /// ```json
4555 ///{
4556 /// "type": "object",
4557 /// "properties": {
4558 /// "config": {
4559 /// "$ref": "#/components/schemas/ConnectWidgetRequest"
4560 /// }
4561 /// }
4562 ///}
4563 /// ```
4564 /// </details>
4565 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
4566 pub struct ConnectWidgetRequestBody {
4567 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
4568 pub config: ::std::option::Option<ConnectWidgetRequest>,
4569 }
4570
4571 impl ::std::convert::From<&ConnectWidgetRequestBody> for ConnectWidgetRequestBody {
4572 fn from(value: &ConnectWidgetRequestBody) -> Self {
4573 value.clone()
4574 }
4575 }
4576
4577 impl ::std::default::Default for ConnectWidgetRequestBody {
4578 fn default() -> Self {
4579 Self {
4580 config: Default::default(),
4581 }
4582 }
4583 }
4584
4585 ///`ConnectWidgetResponse`
4586 ///
4587 /// <details><summary>JSON schema</summary>
4588 ///
4589 /// ```json
4590 ///{
4591 /// "type": "object",
4592 /// "properties": {
4593 /// "connect_widget_url": {
4594 /// "examples": [
4595 /// "https://int-widgets.moneydesktop.com/md/connect/jb1rA14m85tw2lyvpgfx4gc6d3Z8z8Ayb8"
4596 /// ],
4597 /// "type": [
4598 /// "string",
4599 /// "null"
4600 /// ]
4601 /// },
4602 /// "guid": {
4603 /// "examples": [
4604 /// "USR-fa7537f3-48aa-a683-a02a-b18940482f54"
4605 /// ],
4606 /// "type": [
4607 /// "string",
4608 /// "null"
4609 /// ]
4610 /// }
4611 /// }
4612 ///}
4613 /// ```
4614 /// </details>
4615 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
4616 pub struct ConnectWidgetResponse {
4617 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
4618 pub connect_widget_url: ::std::option::Option<::std::string::String>,
4619 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
4620 pub guid: ::std::option::Option<::std::string::String>,
4621 }
4622
4623 impl ::std::convert::From<&ConnectWidgetResponse> for ConnectWidgetResponse {
4624 fn from(value: &ConnectWidgetResponse) -> Self {
4625 value.clone()
4626 }
4627 }
4628
4629 impl ::std::default::Default for ConnectWidgetResponse {
4630 fn default() -> Self {
4631 Self {
4632 connect_widget_url: Default::default(),
4633 guid: Default::default(),
4634 }
4635 }
4636 }
4637
4638 ///`ConnectWidgetResponseBody`
4639 ///
4640 /// <details><summary>JSON schema</summary>
4641 ///
4642 /// ```json
4643 ///{
4644 /// "type": "object",
4645 /// "properties": {
4646 /// "user": {
4647 /// "$ref": "#/components/schemas/ConnectWidgetResponse"
4648 /// }
4649 /// }
4650 ///}
4651 /// ```
4652 /// </details>
4653 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
4654 pub struct ConnectWidgetResponseBody {
4655 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
4656 pub user: ::std::option::Option<ConnectWidgetResponse>,
4657 }
4658
4659 impl ::std::convert::From<&ConnectWidgetResponseBody> for ConnectWidgetResponseBody {
4660 fn from(value: &ConnectWidgetResponseBody) -> Self {
4661 value.clone()
4662 }
4663 }
4664
4665 impl ::std::default::Default for ConnectWidgetResponseBody {
4666 fn default() -> Self {
4667 Self {
4668 user: Default::default(),
4669 }
4670 }
4671 }
4672
4673 ///`CredentialRequest`
4674 ///
4675 /// <details><summary>JSON schema</summary>
4676 ///
4677 /// ```json
4678 ///{
4679 /// "type": "object",
4680 /// "properties": {
4681 /// "guid": {
4682 /// "examples": [
4683 /// "CRD-27d0edb8-1d50-5b90-bcbc-be270ca42b9f"
4684 /// ],
4685 /// "type": "string"
4686 /// },
4687 /// "value": {
4688 /// "examples": [
4689 /// "password"
4690 /// ],
4691 /// "type": "string"
4692 /// }
4693 /// }
4694 ///}
4695 /// ```
4696 /// </details>
4697 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
4698 pub struct CredentialRequest {
4699 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
4700 pub guid: ::std::option::Option<::std::string::String>,
4701 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
4702 pub value: ::std::option::Option<::std::string::String>,
4703 }
4704
4705 impl ::std::convert::From<&CredentialRequest> for CredentialRequest {
4706 fn from(value: &CredentialRequest) -> Self {
4707 value.clone()
4708 }
4709 }
4710
4711 impl ::std::default::Default for CredentialRequest {
4712 fn default() -> Self {
4713 Self {
4714 guid: Default::default(),
4715 value: Default::default(),
4716 }
4717 }
4718 }
4719
4720 ///`CredentialResponse`
4721 ///
4722 /// <details><summary>JSON schema</summary>
4723 ///
4724 /// ```json
4725 ///{
4726 /// "type": "object",
4727 /// "properties": {
4728 /// "display_order": {
4729 /// "examples": [
4730 /// 1
4731 /// ],
4732 /// "type": [
4733 /// "integer",
4734 /// "null"
4735 /// ]
4736 /// },
4737 /// "field_name": {
4738 /// "examples": [
4739 /// "LOGIN"
4740 /// ],
4741 /// "type": [
4742 /// "string",
4743 /// "null"
4744 /// ]
4745 /// },
4746 /// "field_type": {
4747 /// "examples": [
4748 /// "TEXT"
4749 /// ],
4750 /// "type": [
4751 /// "string",
4752 /// "null"
4753 /// ]
4754 /// },
4755 /// "guid": {
4756 /// "examples": [
4757 /// "CRD-1ec152cd-e628-e81a-e852-d1e7104624da"
4758 /// ],
4759 /// "type": [
4760 /// "string",
4761 /// "null"
4762 /// ]
4763 /// },
4764 /// "label": {
4765 /// "examples": [
4766 /// "Username"
4767 /// ],
4768 /// "type": [
4769 /// "string",
4770 /// "null"
4771 /// ]
4772 /// },
4773 /// "type": {
4774 /// "examples": [
4775 /// "TEXT"
4776 /// ],
4777 /// "type": [
4778 /// "string",
4779 /// "null"
4780 /// ]
4781 /// }
4782 /// }
4783 ///}
4784 /// ```
4785 /// </details>
4786 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
4787 pub struct CredentialResponse {
4788 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
4789 pub display_order: ::std::option::Option<i64>,
4790 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
4791 pub field_name: ::std::option::Option<::std::string::String>,
4792 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
4793 pub field_type: ::std::option::Option<::std::string::String>,
4794 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
4795 pub guid: ::std::option::Option<::std::string::String>,
4796 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
4797 pub label: ::std::option::Option<::std::string::String>,
4798 #[serde(
4799 rename = "type",
4800 default,
4801 skip_serializing_if = "::std::option::Option::is_none"
4802 )]
4803 pub type_: ::std::option::Option<::std::string::String>,
4804 }
4805
4806 impl ::std::convert::From<&CredentialResponse> for CredentialResponse {
4807 fn from(value: &CredentialResponse) -> Self {
4808 value.clone()
4809 }
4810 }
4811
4812 impl ::std::default::Default for CredentialResponse {
4813 fn default() -> Self {
4814 Self {
4815 display_order: Default::default(),
4816 field_name: Default::default(),
4817 field_type: Default::default(),
4818 guid: Default::default(),
4819 label: Default::default(),
4820 type_: Default::default(),
4821 }
4822 }
4823 }
4824
4825 ///`CredentialsResponseBody`
4826 ///
4827 /// <details><summary>JSON schema</summary>
4828 ///
4829 /// ```json
4830 ///{
4831 /// "type": "object",
4832 /// "properties": {
4833 /// "credentials": {
4834 /// "type": "array",
4835 /// "items": {
4836 /// "$ref": "#/components/schemas/CredentialResponse"
4837 /// }
4838 /// },
4839 /// "pagination": {
4840 /// "$ref": "#/components/schemas/PaginationResponse"
4841 /// }
4842 /// }
4843 ///}
4844 /// ```
4845 /// </details>
4846 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
4847 pub struct CredentialsResponseBody {
4848 #[serde(default, skip_serializing_if = "::std::vec::Vec::is_empty")]
4849 pub credentials: ::std::vec::Vec<CredentialResponse>,
4850 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
4851 pub pagination: ::std::option::Option<PaginationResponse>,
4852 }
4853
4854 impl ::std::convert::From<&CredentialsResponseBody> for CredentialsResponseBody {
4855 fn from(value: &CredentialsResponseBody) -> Self {
4856 value.clone()
4857 }
4858 }
4859
4860 impl ::std::default::Default for CredentialsResponseBody {
4861 fn default() -> Self {
4862 Self {
4863 credentials: Default::default(),
4864 pagination: Default::default(),
4865 }
4866 }
4867 }
4868
4869 ///`CreditCardProduct`
4870 ///
4871 /// <details><summary>JSON schema</summary>
4872 ///
4873 /// ```json
4874 ///{
4875 /// "properties": {
4876 /// "annual_fee": {
4877 /// "examples": [
4878 /// 45
4879 /// ],
4880 /// "type": "number"
4881 /// },
4882 /// "duration_of_introductory_rate_on_balance_transfer": {
4883 /// "type": [
4884 /// "integer",
4885 /// "null"
4886 /// ]
4887 /// },
4888 /// "duration_of_introductory_rate_on_purchases": {
4889 /// "type": [
4890 /// "integer",
4891 /// "null"
4892 /// ]
4893 /// },
4894 /// "guid": {
4895 /// "examples": [
4896 /// "CCA-b5bcd822-6d01-4e23-b8d6-846a225e714a"
4897 /// ],
4898 /// "type": "string"
4899 /// },
4900 /// "has_cashback_rewards": {
4901 /// "examples": [
4902 /// false
4903 /// ],
4904 /// "type": "boolean"
4905 /// },
4906 /// "has_other_rewards": {
4907 /// "examples": [
4908 /// true
4909 /// ],
4910 /// "type": "boolean"
4911 /// },
4912 /// "has_travel_rewards": {
4913 /// "examples": [
4914 /// true
4915 /// ],
4916 /// "type": "boolean"
4917 /// },
4918 /// "has_zero_introductory_annual_fee": {
4919 /// "examples": [
4920 /// true
4921 /// ],
4922 /// "type": "boolean"
4923 /// },
4924 /// "has_zero_percent_introductory_rate": {
4925 /// "examples": [
4926 /// false
4927 /// ],
4928 /// "type": "boolean"
4929 /// },
4930 /// "has_zero_percent_introductory_rate_on_balance_transfer": {
4931 /// "examples": [
4932 /// true
4933 /// ],
4934 /// "type": "boolean"
4935 /// },
4936 /// "is_accepting_applicants": {
4937 /// "examples": [
4938 /// true
4939 /// ],
4940 /// "type": "boolean"
4941 /// },
4942 /// "is_active_credit_card_product": {
4943 /// "examples": [
4944 /// true
4945 /// ],
4946 /// "type": "boolean"
4947 /// },
4948 /// "is_small_business_card": {
4949 /// "examples": [
4950 /// true
4951 /// ],
4952 /// "type": "boolean"
4953 /// },
4954 /// "name": {
4955 /// "examples": [
4956 /// "Chase Credit Card"
4957 /// ],
4958 /// "type": "string"
4959 /// }
4960 /// }
4961 ///}
4962 /// ```
4963 /// </details>
4964 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
4965 pub struct CreditCardProduct {
4966 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
4967 pub annual_fee: ::std::option::Option<f64>,
4968 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
4969 pub duration_of_introductory_rate_on_balance_transfer: ::std::option::Option<i64>,
4970 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
4971 pub duration_of_introductory_rate_on_purchases: ::std::option::Option<i64>,
4972 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
4973 pub guid: ::std::option::Option<::std::string::String>,
4974 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
4975 pub has_cashback_rewards: ::std::option::Option<bool>,
4976 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
4977 pub has_other_rewards: ::std::option::Option<bool>,
4978 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
4979 pub has_travel_rewards: ::std::option::Option<bool>,
4980 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
4981 pub has_zero_introductory_annual_fee: ::std::option::Option<bool>,
4982 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
4983 pub has_zero_percent_introductory_rate: ::std::option::Option<bool>,
4984 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
4985 pub has_zero_percent_introductory_rate_on_balance_transfer: ::std::option::Option<bool>,
4986 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
4987 pub is_accepting_applicants: ::std::option::Option<bool>,
4988 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
4989 pub is_active_credit_card_product: ::std::option::Option<bool>,
4990 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
4991 pub is_small_business_card: ::std::option::Option<bool>,
4992 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
4993 pub name: ::std::option::Option<::std::string::String>,
4994 }
4995
4996 impl ::std::convert::From<&CreditCardProduct> for CreditCardProduct {
4997 fn from(value: &CreditCardProduct) -> Self {
4998 value.clone()
4999 }
5000 }
5001
5002 impl ::std::default::Default for CreditCardProduct {
5003 fn default() -> Self {
5004 Self {
5005 annual_fee: Default::default(),
5006 duration_of_introductory_rate_on_balance_transfer: Default::default(),
5007 duration_of_introductory_rate_on_purchases: Default::default(),
5008 guid: Default::default(),
5009 has_cashback_rewards: Default::default(),
5010 has_other_rewards: Default::default(),
5011 has_travel_rewards: Default::default(),
5012 has_zero_introductory_annual_fee: Default::default(),
5013 has_zero_percent_introductory_rate: Default::default(),
5014 has_zero_percent_introductory_rate_on_balance_transfer: Default::default(),
5015 is_accepting_applicants: Default::default(),
5016 is_active_credit_card_product: Default::default(),
5017 is_small_business_card: Default::default(),
5018 name: Default::default(),
5019 }
5020 }
5021 }
5022
5023 ///`CreditCardProductResponse`
5024 ///
5025 /// <details><summary>JSON schema</summary>
5026 ///
5027 /// ```json
5028 ///{
5029 /// "type": "object",
5030 /// "properties": {
5031 /// "credit_card_product": {
5032 /// "$ref": "#/components/schemas/CreditCardProduct"
5033 /// }
5034 /// }
5035 ///}
5036 /// ```
5037 /// </details>
5038 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
5039 pub struct CreditCardProductResponse {
5040 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
5041 pub credit_card_product: ::std::option::Option<CreditCardProduct>,
5042 }
5043
5044 impl ::std::convert::From<&CreditCardProductResponse> for CreditCardProductResponse {
5045 fn from(value: &CreditCardProductResponse) -> Self {
5046 value.clone()
5047 }
5048 }
5049
5050 impl ::std::default::Default for CreditCardProductResponse {
5051 fn default() -> Self {
5052 Self {
5053 credit_card_product: Default::default(),
5054 }
5055 }
5056 }
5057
5058 ///`EnhanceTransactionResponse`
5059 ///
5060 /// <details><summary>JSON schema</summary>
5061 ///
5062 /// ```json
5063 ///{
5064 /// "type": "object",
5065 /// "properties": {
5066 /// "amount": {
5067 /// "examples": [
5068 /// 21.33
5069 /// ],
5070 /// "type": [
5071 /// "number",
5072 /// "null"
5073 /// ]
5074 /// },
5075 /// "categorized_by": {
5076 /// "examples": [
5077 /// 13
5078 /// ],
5079 /// "type": [
5080 /// "integer",
5081 /// "null"
5082 /// ]
5083 /// },
5084 /// "category": {
5085 /// "examples": [
5086 /// "Rental Car & Taxi"
5087 /// ],
5088 /// "type": [
5089 /// "string",
5090 /// "null"
5091 /// ]
5092 /// },
5093 /// "category_guid": {
5094 /// "examples": [
5095 /// "CAT-9588eaad-90a4-bb5c-66c8-1812503d0db8"
5096 /// ],
5097 /// "type": [
5098 /// "string",
5099 /// "null"
5100 /// ]
5101 /// },
5102 /// "described_by": {
5103 /// "examples": [
5104 /// 6
5105 /// ],
5106 /// "type": [
5107 /// "integer",
5108 /// "null"
5109 /// ]
5110 /// },
5111 /// "description": {
5112 /// "examples": [
5113 /// "Uber"
5114 /// ],
5115 /// "type": [
5116 /// "string",
5117 /// "null"
5118 /// ]
5119 /// },
5120 /// "extended_transaction_type": {
5121 /// "examples": [
5122 /// "partner_transaction_type"
5123 /// ],
5124 /// "type": [
5125 /// "string",
5126 /// "null"
5127 /// ]
5128 /// },
5129 /// "id": {
5130 /// "examples": [
5131 /// "ID-123"
5132 /// ],
5133 /// "type": [
5134 /// "string",
5135 /// "null"
5136 /// ]
5137 /// },
5138 /// "is_bill_pay": {
5139 /// "examples": [
5140 /// false
5141 /// ],
5142 /// "type": [
5143 /// "boolean",
5144 /// "null"
5145 /// ]
5146 /// },
5147 /// "is_direct_deposit": {
5148 /// "examples": [
5149 /// false
5150 /// ],
5151 /// "type": [
5152 /// "boolean",
5153 /// "null"
5154 /// ]
5155 /// },
5156 /// "is_expense": {
5157 /// "examples": [
5158 /// false
5159 /// ],
5160 /// "type": [
5161 /// "boolean",
5162 /// "null"
5163 /// ]
5164 /// },
5165 /// "is_fee": {
5166 /// "examples": [
5167 /// false
5168 /// ],
5169 /// "type": [
5170 /// "boolean",
5171 /// "null"
5172 /// ]
5173 /// },
5174 /// "is_income": {
5175 /// "examples": [
5176 /// false
5177 /// ],
5178 /// "type": [
5179 /// "boolean",
5180 /// "null"
5181 /// ]
5182 /// },
5183 /// "is_international": {
5184 /// "examples": [
5185 /// false
5186 /// ],
5187 /// "type": [
5188 /// "boolean",
5189 /// "null"
5190 /// ]
5191 /// },
5192 /// "is_overdraft_fee": {
5193 /// "examples": [
5194 /// false
5195 /// ],
5196 /// "type": [
5197 /// "boolean",
5198 /// "null"
5199 /// ]
5200 /// },
5201 /// "is_payroll_advance": {
5202 /// "examples": [
5203 /// false
5204 /// ],
5205 /// "type": [
5206 /// "boolean",
5207 /// "null"
5208 /// ]
5209 /// },
5210 /// "is_subscription": {
5211 /// "examples": [
5212 /// false
5213 /// ],
5214 /// "type": [
5215 /// "boolean",
5216 /// "null"
5217 /// ]
5218 /// },
5219 /// "memo": {
5220 /// "examples": [
5221 /// "Additional-information*on_transaction"
5222 /// ],
5223 /// "type": [
5224 /// "string",
5225 /// "null"
5226 /// ]
5227 /// },
5228 /// "merchant_category_code": {
5229 /// "examples": [
5230 /// 4121
5231 /// ],
5232 /// "type": [
5233 /// "integer",
5234 /// "null"
5235 /// ]
5236 /// },
5237 /// "merchant_guid": {
5238 /// "examples": [
5239 /// "MCH-14f25b63-ef47-a38e-b2b6-d02b280b6e4e"
5240 /// ],
5241 /// "type": [
5242 /// "string",
5243 /// "null"
5244 /// ]
5245 /// },
5246 /// "merchant_location_guid": {
5247 /// "examples": [
5248 /// "MCL-00024e59-18b5-4d79-b879-2a7896726fea"
5249 /// ],
5250 /// "type": [
5251 /// "string",
5252 /// "null"
5253 /// ]
5254 /// },
5255 /// "original_description": {
5256 /// "examples": [
5257 /// "ubr* pending.uber.com"
5258 /// ],
5259 /// "type": [
5260 /// "string",
5261 /// "null"
5262 /// ]
5263 /// },
5264 /// "type": {
5265 /// "examples": [
5266 /// "DEBIT"
5267 /// ],
5268 /// "type": [
5269 /// "string",
5270 /// "null"
5271 /// ]
5272 /// }
5273 /// }
5274 ///}
5275 /// ```
5276 /// </details>
5277 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
5278 pub struct EnhanceTransactionResponse {
5279 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
5280 pub amount: ::std::option::Option<f64>,
5281 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
5282 pub categorized_by: ::std::option::Option<i64>,
5283 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
5284 pub category: ::std::option::Option<::std::string::String>,
5285 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
5286 pub category_guid: ::std::option::Option<::std::string::String>,
5287 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
5288 pub described_by: ::std::option::Option<i64>,
5289 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
5290 pub description: ::std::option::Option<::std::string::String>,
5291 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
5292 pub extended_transaction_type: ::std::option::Option<::std::string::String>,
5293 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
5294 pub id: ::std::option::Option<::std::string::String>,
5295 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
5296 pub is_bill_pay: ::std::option::Option<bool>,
5297 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
5298 pub is_direct_deposit: ::std::option::Option<bool>,
5299 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
5300 pub is_expense: ::std::option::Option<bool>,
5301 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
5302 pub is_fee: ::std::option::Option<bool>,
5303 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
5304 pub is_income: ::std::option::Option<bool>,
5305 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
5306 pub is_international: ::std::option::Option<bool>,
5307 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
5308 pub is_overdraft_fee: ::std::option::Option<bool>,
5309 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
5310 pub is_payroll_advance: ::std::option::Option<bool>,
5311 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
5312 pub is_subscription: ::std::option::Option<bool>,
5313 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
5314 pub memo: ::std::option::Option<::std::string::String>,
5315 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
5316 pub merchant_category_code: ::std::option::Option<i64>,
5317 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
5318 pub merchant_guid: ::std::option::Option<::std::string::String>,
5319 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
5320 pub merchant_location_guid: ::std::option::Option<::std::string::String>,
5321 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
5322 pub original_description: ::std::option::Option<::std::string::String>,
5323 #[serde(
5324 rename = "type",
5325 default,
5326 skip_serializing_if = "::std::option::Option::is_none"
5327 )]
5328 pub type_: ::std::option::Option<::std::string::String>,
5329 }
5330
5331 impl ::std::convert::From<&EnhanceTransactionResponse> for EnhanceTransactionResponse {
5332 fn from(value: &EnhanceTransactionResponse) -> Self {
5333 value.clone()
5334 }
5335 }
5336
5337 impl ::std::default::Default for EnhanceTransactionResponse {
5338 fn default() -> Self {
5339 Self {
5340 amount: Default::default(),
5341 categorized_by: Default::default(),
5342 category: Default::default(),
5343 category_guid: Default::default(),
5344 described_by: Default::default(),
5345 description: Default::default(),
5346 extended_transaction_type: Default::default(),
5347 id: Default::default(),
5348 is_bill_pay: Default::default(),
5349 is_direct_deposit: Default::default(),
5350 is_expense: Default::default(),
5351 is_fee: Default::default(),
5352 is_income: Default::default(),
5353 is_international: Default::default(),
5354 is_overdraft_fee: Default::default(),
5355 is_payroll_advance: Default::default(),
5356 is_subscription: Default::default(),
5357 memo: Default::default(),
5358 merchant_category_code: Default::default(),
5359 merchant_guid: Default::default(),
5360 merchant_location_guid: Default::default(),
5361 original_description: Default::default(),
5362 type_: Default::default(),
5363 }
5364 }
5365 }
5366
5367 ///`EnhanceTransactionsRequest`
5368 ///
5369 /// <details><summary>JSON schema</summary>
5370 ///
5371 /// ```json
5372 ///{
5373 /// "type": "object",
5374 /// "required": [
5375 /// "description",
5376 /// "id"
5377 /// ],
5378 /// "properties": {
5379 /// "amount": {
5380 /// "examples": [
5381 /// 21.33
5382 /// ],
5383 /// "type": "number"
5384 /// },
5385 /// "description": {
5386 /// "examples": [
5387 /// "ubr* pending.uber.com"
5388 /// ],
5389 /// "type": "string"
5390 /// },
5391 /// "extended_transaction_type": {
5392 /// "examples": [
5393 /// "partner_transaction_type"
5394 /// ],
5395 /// "type": "string"
5396 /// },
5397 /// "id": {
5398 /// "examples": [
5399 /// "ID-123"
5400 /// ],
5401 /// "type": "string"
5402 /// },
5403 /// "memo": {
5404 /// "examples": [
5405 /// "Additional-information*on_transaction"
5406 /// ],
5407 /// "type": "string"
5408 /// },
5409 /// "merchant_category_code": {
5410 /// "examples": [
5411 /// 4121
5412 /// ],
5413 /// "type": "integer"
5414 /// },
5415 /// "type": {
5416 /// "examples": [
5417 /// "DEBIT"
5418 /// ],
5419 /// "type": "string"
5420 /// }
5421 /// }
5422 ///}
5423 /// ```
5424 /// </details>
5425 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
5426 pub struct EnhanceTransactionsRequest {
5427 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
5428 pub amount: ::std::option::Option<f64>,
5429 pub description: ::std::string::String,
5430 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
5431 pub extended_transaction_type: ::std::option::Option<::std::string::String>,
5432 pub id: ::std::string::String,
5433 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
5434 pub memo: ::std::option::Option<::std::string::String>,
5435 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
5436 pub merchant_category_code: ::std::option::Option<i64>,
5437 #[serde(
5438 rename = "type",
5439 default,
5440 skip_serializing_if = "::std::option::Option::is_none"
5441 )]
5442 pub type_: ::std::option::Option<::std::string::String>,
5443 }
5444
5445 impl ::std::convert::From<&EnhanceTransactionsRequest> for EnhanceTransactionsRequest {
5446 fn from(value: &EnhanceTransactionsRequest) -> Self {
5447 value.clone()
5448 }
5449 }
5450
5451 ///`EnhanceTransactionsRequestBody`
5452 ///
5453 /// <details><summary>JSON schema</summary>
5454 ///
5455 /// ```json
5456 ///{
5457 /// "type": "object",
5458 /// "properties": {
5459 /// "transactions": {
5460 /// "type": "array",
5461 /// "items": {
5462 /// "$ref": "#/components/schemas/EnhanceTransactionsRequest"
5463 /// }
5464 /// }
5465 /// }
5466 ///}
5467 /// ```
5468 /// </details>
5469 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
5470 pub struct EnhanceTransactionsRequestBody {
5471 #[serde(default, skip_serializing_if = "::std::vec::Vec::is_empty")]
5472 pub transactions: ::std::vec::Vec<EnhanceTransactionsRequest>,
5473 }
5474
5475 impl ::std::convert::From<&EnhanceTransactionsRequestBody> for EnhanceTransactionsRequestBody {
5476 fn from(value: &EnhanceTransactionsRequestBody) -> Self {
5477 value.clone()
5478 }
5479 }
5480
5481 impl ::std::default::Default for EnhanceTransactionsRequestBody {
5482 fn default() -> Self {
5483 Self {
5484 transactions: Default::default(),
5485 }
5486 }
5487 }
5488
5489 ///`EnhanceTransactionsResponseBody`
5490 ///
5491 /// <details><summary>JSON schema</summary>
5492 ///
5493 /// ```json
5494 ///{
5495 /// "type": "object",
5496 /// "properties": {
5497 /// "transactions": {
5498 /// "type": "array",
5499 /// "items": {
5500 /// "$ref": "#/components/schemas/EnhanceTransactionResponse"
5501 /// }
5502 /// }
5503 /// }
5504 ///}
5505 /// ```
5506 /// </details>
5507 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
5508 pub struct EnhanceTransactionsResponseBody {
5509 #[serde(default, skip_serializing_if = "::std::vec::Vec::is_empty")]
5510 pub transactions: ::std::vec::Vec<EnhanceTransactionResponse>,
5511 }
5512
5513 impl ::std::convert::From<&EnhanceTransactionsResponseBody> for EnhanceTransactionsResponseBody {
5514 fn from(value: &EnhanceTransactionsResponseBody) -> Self {
5515 value.clone()
5516 }
5517 }
5518
5519 impl ::std::default::Default for EnhanceTransactionsResponseBody {
5520 fn default() -> Self {
5521 Self {
5522 transactions: Default::default(),
5523 }
5524 }
5525 }
5526
5527 ///`GoalRequest`
5528 ///
5529 /// <details><summary>JSON schema</summary>
5530 ///
5531 /// ```json
5532 ///{
5533 /// "type": "object",
5534 /// "required": [
5535 /// "account_guid",
5536 /// "amount",
5537 /// "goal_type_name",
5538 /// "meta_type_name",
5539 /// "name"
5540 /// ],
5541 /// "properties": {
5542 /// "account_guid": {
5543 /// "description": "Unique identifier of the account for the goal.",
5544 /// "examples": [
5545 /// "ACT-4e431124-4a29-abf9-f059-ab232ac14dbf"
5546 /// ],
5547 /// "type": "string"
5548 /// },
5549 /// "amount": {
5550 /// "description": "Amount of the goal.",
5551 /// "examples": [
5552 /// 4500.5
5553 /// ],
5554 /// "type": "number"
5555 /// },
5556 /// "completed_at": {
5557 /// "description": "Date and time the goal was completed.",
5558 /// "examples": [
5559 /// "2015-06-19T10:37:04-06:00"
5560 /// ],
5561 /// "type": "string"
5562 /// },
5563 /// "goal_type_name": {
5564 /// "description": "The goal type.",
5565 /// "examples": [
5566 /// "PAYOFF"
5567 /// ],
5568 /// "type": "string"
5569 /// },
5570 /// "has_been_spent": {
5571 /// "description": "Determines if the goal has been spent.",
5572 /// "examples": [
5573 /// false
5574 /// ],
5575 /// "type": "boolean"
5576 /// },
5577 /// "is_complete": {
5578 /// "description": "Determines if the goal is complete.",
5579 /// "examples": [
5580 /// false
5581 /// ],
5582 /// "type": "boolean"
5583 /// },
5584 /// "meta_type_name": {
5585 /// "description": "The category of the goal.",
5586 /// "examples": [
5587 /// "VACATION"
5588 /// ],
5589 /// "type": "string"
5590 /// },
5591 /// "metadata": {
5592 /// "description": "Additional information a partner can store on the
5593 /// goal.",
5594 /// "examples": [
5595 /// "Additional information"
5596 /// ],
5597 /// "type": "string"
5598 /// },
5599 /// "name": {
5600 /// "description": "The name of the goal.",
5601 /// "examples": [
5602 /// "Save for Europe"
5603 /// ],
5604 /// "type": "string"
5605 /// },
5606 /// "position": {
5607 /// "description": "The priority of the goal in relation to multiple
5608 /// goals.",
5609 /// "examples": [
5610 /// 3
5611 /// ],
5612 /// "type": "integer"
5613 /// },
5614 /// "targeted_to_complete_at": {
5615 /// "description": "Date and time the goal is to complete. Intended for
5616 /// users to set their own goal completion dates.",
5617 /// "examples": [
5618 /// "2026-12-08 00:00:00.000000"
5619 /// ],
5620 /// "type": "string"
5621 /// }
5622 /// }
5623 ///}
5624 /// ```
5625 /// </details>
5626 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
5627 pub struct GoalRequest {
5628 ///Unique identifier of the account for the goal.
5629 pub account_guid: ::std::string::String,
5630 pub amount: f64,
5631 ///Date and time the goal was completed.
5632 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
5633 pub completed_at: ::std::option::Option<::std::string::String>,
5634 ///The goal type.
5635 pub goal_type_name: ::std::string::String,
5636 ///Determines if the goal has been spent.
5637 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
5638 pub has_been_spent: ::std::option::Option<bool>,
5639 ///Determines if the goal is complete.
5640 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
5641 pub is_complete: ::std::option::Option<bool>,
5642 ///The category of the goal.
5643 pub meta_type_name: ::std::string::String,
5644 ///Additional information a partner can store on the goal.
5645 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
5646 pub metadata: ::std::option::Option<::std::string::String>,
5647 ///The name of the goal.
5648 pub name: ::std::string::String,
5649 ///The priority of the goal in relation to multiple goals.
5650 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
5651 pub position: ::std::option::Option<i64>,
5652 ///Date and time the goal is to complete. Intended for users to set
5653 /// their own goal completion dates.
5654 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
5655 pub targeted_to_complete_at: ::std::option::Option<::std::string::String>,
5656 }
5657
5658 impl ::std::convert::From<&GoalRequest> for GoalRequest {
5659 fn from(value: &GoalRequest) -> Self {
5660 value.clone()
5661 }
5662 }
5663
5664 ///`GoalRequestBody`
5665 ///
5666 /// <details><summary>JSON schema</summary>
5667 ///
5668 /// ```json
5669 ///{
5670 /// "type": "object",
5671 /// "properties": {
5672 /// "goal": {
5673 /// "$ref": "#/components/schemas/GoalRequest"
5674 /// }
5675 /// }
5676 ///}
5677 /// ```
5678 /// </details>
5679 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
5680 pub struct GoalRequestBody {
5681 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
5682 pub goal: ::std::option::Option<GoalRequest>,
5683 }
5684
5685 impl ::std::convert::From<&GoalRequestBody> for GoalRequestBody {
5686 fn from(value: &GoalRequestBody) -> Self {
5687 value.clone()
5688 }
5689 }
5690
5691 impl ::std::default::Default for GoalRequestBody {
5692 fn default() -> Self {
5693 Self {
5694 goal: Default::default(),
5695 }
5696 }
5697 }
5698
5699 ///`GoalResponse`
5700 ///
5701 /// <details><summary>JSON schema</summary>
5702 ///
5703 /// ```json
5704 ///{
5705 /// "properties": {
5706 /// "account_guid": {
5707 /// "description": "Unique identifier of the account for the goal.",
5708 /// "examples": [
5709 /// "ACT-4e431124-4a29-abf9-f059-ab232ac14dbf"
5710 /// ],
5711 /// "type": "string"
5712 /// },
5713 /// "amount": {
5714 /// "description": "Amount of the goal.",
5715 /// "examples": [
5716 /// 4500
5717 /// ],
5718 /// "type": "number"
5719 /// },
5720 /// "completed_at": {
5721 /// "description": "Date and time the goal was completed.",
5722 /// "examples": [
5723 /// "2015-06-19T10:37:04-06:00"
5724 /// ],
5725 /// "type": "string"
5726 /// },
5727 /// "current_amount": {
5728 /// "description": "The current amount of the goal.",
5729 /// "examples": [
5730 /// 1651.27
5731 /// ],
5732 /// "type": "number"
5733 /// },
5734 /// "goal_type_name": {
5735 /// "description": "The goal type.",
5736 /// "examples": [
5737 /// "PAYOFF"
5738 /// ],
5739 /// "type": "string"
5740 /// },
5741 /// "guid": {
5742 /// "description": "Unique identifier for the goal. Defined by MX.",
5743 /// "examples": [
5744 /// "GOL-f223463-4355-48d0-rce7-fe2rb345617c"
5745 /// ],
5746 /// "type": "string"
5747 /// },
5748 /// "has_been_spent": {
5749 /// "description": "Determines if the goal has been spent.",
5750 /// "examples": [
5751 /// false
5752 /// ],
5753 /// "type": "boolean"
5754 /// },
5755 /// "is_complete": {
5756 /// "description": "Determines if the goal is complete.",
5757 /// "examples": [
5758 /// false
5759 /// ],
5760 /// "type": "boolean"
5761 /// },
5762 /// "meta_type_name": {
5763 /// "description": "The category of the goal.",
5764 /// "examples": [
5765 /// "VACATION"
5766 /// ],
5767 /// "type": "string"
5768 /// },
5769 /// "metadata": {
5770 /// "description": "Additional information a partner can store on the
5771 /// goal.",
5772 /// "examples": [
5773 /// "Additional information"
5774 /// ],
5775 /// "type": "string"
5776 /// },
5777 /// "name": {
5778 /// "description": "The name of the goal.",
5779 /// "examples": [
5780 /// "Save for Europe"
5781 /// ],
5782 /// "type": "string"
5783 /// },
5784 /// "position": {
5785 /// "description": "The priority of the goal in relation to multiple
5786 /// goals.",
5787 /// "examples": [
5788 /// 3
5789 /// ],
5790 /// "type": "integer"
5791 /// },
5792 /// "projected_to_complete_at": {
5793 /// "description": "Date and time the goal is projected to be
5794 /// completed.",
5795 /// "examples": [
5796 /// "2022-06-14T16:03:53-00:00"
5797 /// ],
5798 /// "type": "string"
5799 /// },
5800 /// "targeted_to_complete_at": {
5801 /// "description": "Date and time the goal is to complete. Intended for
5802 /// users to set their own goal completion dates.",
5803 /// "examples": [
5804 /// "2026-12-08 00:00:00.000000"
5805 /// ],
5806 /// "type": "string"
5807 /// },
5808 /// "track_type_name": {
5809 /// "examples": [
5810 /// "Track Type Name"
5811 /// ],
5812 /// "type": "string"
5813 /// },
5814 /// "user_guid": {
5815 /// "description": "The unique identifier for the the user. Defined by
5816 /// MX.",
5817 /// "examples": [
5818 /// "USR-11141024-90b3-1bce-cac9-c06ced52ab4c"
5819 /// ],
5820 /// "type": "string"
5821 /// }
5822 /// }
5823 ///}
5824 /// ```
5825 /// </details>
5826 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
5827 pub struct GoalResponse {
5828 ///Unique identifier of the account for the goal.
5829 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
5830 pub account_guid: ::std::option::Option<::std::string::String>,
5831 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
5832 pub amount: ::std::option::Option<f64>,
5833 ///Date and time the goal was completed.
5834 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
5835 pub completed_at: ::std::option::Option<::std::string::String>,
5836 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
5837 pub current_amount: ::std::option::Option<f64>,
5838 ///The goal type.
5839 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
5840 pub goal_type_name: ::std::option::Option<::std::string::String>,
5841 ///Unique identifier for the goal. Defined by MX.
5842 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
5843 pub guid: ::std::option::Option<::std::string::String>,
5844 ///Determines if the goal has been spent.
5845 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
5846 pub has_been_spent: ::std::option::Option<bool>,
5847 ///Determines if the goal is complete.
5848 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
5849 pub is_complete: ::std::option::Option<bool>,
5850 ///The category of the goal.
5851 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
5852 pub meta_type_name: ::std::option::Option<::std::string::String>,
5853 ///Additional information a partner can store on the goal.
5854 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
5855 pub metadata: ::std::option::Option<::std::string::String>,
5856 ///The name of the goal.
5857 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
5858 pub name: ::std::option::Option<::std::string::String>,
5859 ///The priority of the goal in relation to multiple goals.
5860 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
5861 pub position: ::std::option::Option<i64>,
5862 ///Date and time the goal is projected to be completed.
5863 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
5864 pub projected_to_complete_at: ::std::option::Option<::std::string::String>,
5865 ///Date and time the goal is to complete. Intended for users to set
5866 /// their own goal completion dates.
5867 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
5868 pub targeted_to_complete_at: ::std::option::Option<::std::string::String>,
5869 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
5870 pub track_type_name: ::std::option::Option<::std::string::String>,
5871 ///The unique identifier for the the user. Defined by MX.
5872 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
5873 pub user_guid: ::std::option::Option<::std::string::String>,
5874 }
5875
5876 impl ::std::convert::From<&GoalResponse> for GoalResponse {
5877 fn from(value: &GoalResponse) -> Self {
5878 value.clone()
5879 }
5880 }
5881
5882 impl ::std::default::Default for GoalResponse {
5883 fn default() -> Self {
5884 Self {
5885 account_guid: Default::default(),
5886 amount: Default::default(),
5887 completed_at: Default::default(),
5888 current_amount: Default::default(),
5889 goal_type_name: Default::default(),
5890 guid: Default::default(),
5891 has_been_spent: Default::default(),
5892 is_complete: Default::default(),
5893 meta_type_name: Default::default(),
5894 metadata: Default::default(),
5895 name: Default::default(),
5896 position: Default::default(),
5897 projected_to_complete_at: Default::default(),
5898 targeted_to_complete_at: Default::default(),
5899 track_type_name: Default::default(),
5900 user_guid: Default::default(),
5901 }
5902 }
5903 }
5904
5905 ///`GoalResponseBody`
5906 ///
5907 /// <details><summary>JSON schema</summary>
5908 ///
5909 /// ```json
5910 ///{
5911 /// "type": "object",
5912 /// "properties": {
5913 /// "goal": {
5914 /// "$ref": "#/components/schemas/GoalResponse"
5915 /// }
5916 /// }
5917 ///}
5918 /// ```
5919 /// </details>
5920 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
5921 pub struct GoalResponseBody {
5922 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
5923 pub goal: ::std::option::Option<GoalResponse>,
5924 }
5925
5926 impl ::std::convert::From<&GoalResponseBody> for GoalResponseBody {
5927 fn from(value: &GoalResponseBody) -> Self {
5928 value.clone()
5929 }
5930 }
5931
5932 impl ::std::default::Default for GoalResponseBody {
5933 fn default() -> Self {
5934 Self {
5935 goal: Default::default(),
5936 }
5937 }
5938 }
5939
5940 ///`GoalsResponse`
5941 ///
5942 /// <details><summary>JSON schema</summary>
5943 ///
5944 /// ```json
5945 ///{
5946 /// "properties": {
5947 /// "account_guid": {
5948 /// "description": "Unique identifier of the account for the goal.",
5949 /// "examples": [
5950 /// "ACT-4e431124-4a29-abf9-f059-ab232ac14dbf"
5951 /// ],
5952 /// "type": "string"
5953 /// },
5954 /// "amount": {
5955 /// "description": "Amount of the goal.",
5956 /// "examples": [
5957 /// 4500
5958 /// ],
5959 /// "type": "number"
5960 /// },
5961 /// "completed_at": {
5962 /// "description": "Date and time the goal was completed.",
5963 /// "examples": [
5964 /// "2015-06-19T10:37:04-06:00"
5965 /// ],
5966 /// "type": "string"
5967 /// },
5968 /// "current_amount": {
5969 /// "description": "The current amount of the goal.",
5970 /// "examples": [
5971 /// 1651.27
5972 /// ],
5973 /// "type": "number"
5974 /// },
5975 /// "goal_type_name": {
5976 /// "description": "The goal type.",
5977 /// "examples": [
5978 /// "PAYOFF"
5979 /// ],
5980 /// "type": "string"
5981 /// },
5982 /// "guid": {
5983 /// "description": "The unique identifier for the goal. Defined by
5984 /// MX.",
5985 /// "examples": [
5986 /// "GOL-524ca5db-a2d5-44f3-b048-16de16059024"
5987 /// ],
5988 /// "type": "string"
5989 /// },
5990 /// "has_been_spent": {
5991 /// "description": "Determines if the goal has been spent.",
5992 /// "examples": [
5993 /// false
5994 /// ],
5995 /// "type": "boolean"
5996 /// },
5997 /// "is_complete": {
5998 /// "description": "Determines if the goal is complete.",
5999 /// "examples": [
6000 /// false
6001 /// ],
6002 /// "type": "boolean"
6003 /// },
6004 /// "meta_type_name": {
6005 /// "description": "The category of the goal.",
6006 /// "examples": [
6007 /// "VACATION"
6008 /// ],
6009 /// "type": "string"
6010 /// },
6011 /// "metadata": {
6012 /// "description": "Additional information a partner can store on the
6013 /// goal.",
6014 /// "examples": [
6015 /// "Additional information"
6016 /// ],
6017 /// "type": "string"
6018 /// },
6019 /// "name": {
6020 /// "description": "The name of the goal.",
6021 /// "examples": [
6022 /// "Save for Europe"
6023 /// ],
6024 /// "type": "string"
6025 /// },
6026 /// "position": {
6027 /// "description": "The priority of the goal in relation to multiple
6028 /// goals.",
6029 /// "examples": [
6030 /// 3
6031 /// ],
6032 /// "type": "integer"
6033 /// },
6034 /// "projected_to_complete_at": {
6035 /// "description": "The date on which the project was completed.",
6036 /// "examples": [
6037 /// "2022-06-14T16:03:53-00:00"
6038 /// ],
6039 /// "type": "string"
6040 /// },
6041 /// "targeted_to_complete_at": {
6042 /// "examples": [
6043 /// "2026-12-08 00:00:00.000000"
6044 /// ],
6045 /// "type": "string"
6046 /// },
6047 /// "track_type_name": {
6048 /// "examples": [
6049 /// "Track Type Name"
6050 /// ],
6051 /// "type": "string"
6052 /// },
6053 /// "user_guid": {
6054 /// "description": "The unique identifier for the the user. Defined by
6055 /// MX.",
6056 /// "examples": [
6057 /// "USR-11141024-90b3-1bce-cac9-c06ced52ab4c"
6058 /// ],
6059 /// "type": "string"
6060 /// }
6061 /// }
6062 ///}
6063 /// ```
6064 /// </details>
6065 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
6066 pub struct GoalsResponse {
6067 ///Unique identifier of the account for the goal.
6068 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
6069 pub account_guid: ::std::option::Option<::std::string::String>,
6070 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
6071 pub amount: ::std::option::Option<f64>,
6072 ///Date and time the goal was completed.
6073 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
6074 pub completed_at: ::std::option::Option<::std::string::String>,
6075 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
6076 pub current_amount: ::std::option::Option<f64>,
6077 ///The goal type.
6078 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
6079 pub goal_type_name: ::std::option::Option<::std::string::String>,
6080 ///The unique identifier for the goal. Defined by MX.
6081 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
6082 pub guid: ::std::option::Option<::std::string::String>,
6083 ///Determines if the goal has been spent.
6084 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
6085 pub has_been_spent: ::std::option::Option<bool>,
6086 ///Determines if the goal is complete.
6087 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
6088 pub is_complete: ::std::option::Option<bool>,
6089 ///The category of the goal.
6090 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
6091 pub meta_type_name: ::std::option::Option<::std::string::String>,
6092 ///Additional information a partner can store on the goal.
6093 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
6094 pub metadata: ::std::option::Option<::std::string::String>,
6095 ///The name of the goal.
6096 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
6097 pub name: ::std::option::Option<::std::string::String>,
6098 ///The priority of the goal in relation to multiple goals.
6099 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
6100 pub position: ::std::option::Option<i64>,
6101 ///The date on which the project was completed.
6102 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
6103 pub projected_to_complete_at: ::std::option::Option<::std::string::String>,
6104 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
6105 pub targeted_to_complete_at: ::std::option::Option<::std::string::String>,
6106 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
6107 pub track_type_name: ::std::option::Option<::std::string::String>,
6108 ///The unique identifier for the the user. Defined by MX.
6109 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
6110 pub user_guid: ::std::option::Option<::std::string::String>,
6111 }
6112
6113 impl ::std::convert::From<&GoalsResponse> for GoalsResponse {
6114 fn from(value: &GoalsResponse) -> Self {
6115 value.clone()
6116 }
6117 }
6118
6119 impl ::std::default::Default for GoalsResponse {
6120 fn default() -> Self {
6121 Self {
6122 account_guid: Default::default(),
6123 amount: Default::default(),
6124 completed_at: Default::default(),
6125 current_amount: Default::default(),
6126 goal_type_name: Default::default(),
6127 guid: Default::default(),
6128 has_been_spent: Default::default(),
6129 is_complete: Default::default(),
6130 meta_type_name: Default::default(),
6131 metadata: Default::default(),
6132 name: Default::default(),
6133 position: Default::default(),
6134 projected_to_complete_at: Default::default(),
6135 targeted_to_complete_at: Default::default(),
6136 track_type_name: Default::default(),
6137 user_guid: Default::default(),
6138 }
6139 }
6140 }
6141
6142 ///`GoalsResponseBody`
6143 ///
6144 /// <details><summary>JSON schema</summary>
6145 ///
6146 /// ```json
6147 ///{
6148 /// "type": "object",
6149 /// "properties": {
6150 /// "goals": {
6151 /// "type": "array",
6152 /// "items": {
6153 /// "$ref": "#/components/schemas/GoalsResponse"
6154 /// }
6155 /// },
6156 /// "pagination": {
6157 /// "$ref": "#/components/schemas/PaginationResponse"
6158 /// }
6159 /// }
6160 ///}
6161 /// ```
6162 /// </details>
6163 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
6164 pub struct GoalsResponseBody {
6165 #[serde(default, skip_serializing_if = "::std::vec::Vec::is_empty")]
6166 pub goals: ::std::vec::Vec<GoalsResponse>,
6167 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
6168 pub pagination: ::std::option::Option<PaginationResponse>,
6169 }
6170
6171 impl ::std::convert::From<&GoalsResponseBody> for GoalsResponseBody {
6172 fn from(value: &GoalsResponseBody) -> Self {
6173 value.clone()
6174 }
6175 }
6176
6177 impl ::std::default::Default for GoalsResponseBody {
6178 fn default() -> Self {
6179 Self {
6180 goals: Default::default(),
6181 pagination: Default::default(),
6182 }
6183 }
6184 }
6185
6186 ///`ImageOptionResponse`
6187 ///
6188 /// <details><summary>JSON schema</summary>
6189 ///
6190 /// ```json
6191 ///{
6192 /// "type": "object",
6193 /// "properties": {
6194 /// "data_uri": {
6195 /// "examples": [
6196 /// "data:image/png;base64,iVBORw0KGgoAAAANSUh ... more image data
6197 /// ..."
6198 /// ],
6199 /// "type": [
6200 /// "string",
6201 /// "null"
6202 /// ]
6203 /// },
6204 /// "guid": {
6205 /// "examples": [
6206 /// "CRD-ce76d2e3-86bd-ec4a-ec52-eb53b5194bf5"
6207 /// ],
6208 /// "type": [
6209 /// "string",
6210 /// "null"
6211 /// ]
6212 /// },
6213 /// "label": {
6214 /// "examples": [
6215 /// "IMAGE_1"
6216 /// ],
6217 /// "type": [
6218 /// "string",
6219 /// "null"
6220 /// ]
6221 /// },
6222 /// "value": {
6223 /// "examples": [
6224 /// "image_data"
6225 /// ],
6226 /// "type": [
6227 /// "string",
6228 /// "null"
6229 /// ]
6230 /// }
6231 /// }
6232 ///}
6233 /// ```
6234 /// </details>
6235 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
6236 pub struct ImageOptionResponse {
6237 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
6238 pub data_uri: ::std::option::Option<::std::string::String>,
6239 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
6240 pub guid: ::std::option::Option<::std::string::String>,
6241 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
6242 pub label: ::std::option::Option<::std::string::String>,
6243 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
6244 pub value: ::std::option::Option<::std::string::String>,
6245 }
6246
6247 impl ::std::convert::From<&ImageOptionResponse> for ImageOptionResponse {
6248 fn from(value: &ImageOptionResponse) -> Self {
6249 value.clone()
6250 }
6251 }
6252
6253 impl ::std::default::Default for ImageOptionResponse {
6254 fn default() -> Self {
6255 Self {
6256 data_uri: Default::default(),
6257 guid: Default::default(),
6258 label: Default::default(),
6259 value: Default::default(),
6260 }
6261 }
6262 }
6263
6264 ///`InsightResponse`
6265 ///
6266 /// <details><summary>JSON schema</summary>
6267 ///
6268 /// ```json
6269 ///{
6270 /// "type": "object",
6271 /// "properties": {
6272 /// "active_at": {
6273 /// "examples": [
6274 /// "2022-01-07T12:00:00Z"
6275 /// ],
6276 /// "type": [
6277 /// "string",
6278 /// "null"
6279 /// ]
6280 /// },
6281 /// "client_guid": {
6282 /// "examples": [
6283 /// "CLT-abcd-1234"
6284 /// ],
6285 /// "type": [
6286 /// "string",
6287 /// "null"
6288 /// ]
6289 /// },
6290 /// "created_at": {
6291 /// "examples": [
6292 /// "2022-01-12T18:16:51Z"
6293 /// ],
6294 /// "type": [
6295 /// "string",
6296 /// "null"
6297 /// ]
6298 /// },
6299 /// "cta_clicked_at": {
6300 /// "examples": [
6301 /// "2022-01-13T18:13:51Z"
6302 /// ],
6303 /// "type": [
6304 /// "string",
6305 /// "null"
6306 /// ]
6307 /// },
6308 /// "description": {
6309 /// "examples": [
6310 /// "Gold's Gym charged you $36.71 more this month than normal. Did
6311 /// you upgrade your service?"
6312 /// ],
6313 /// "type": [
6314 /// "string",
6315 /// "null"
6316 /// ]
6317 /// },
6318 /// "guid": {
6319 /// "examples": [
6320 /// "BET-abcd-1234"
6321 /// ],
6322 /// "type": [
6323 /// "string",
6324 /// "null"
6325 /// ]
6326 /// },
6327 /// "has_associated_accounts": {
6328 /// "examples": [
6329 /// false
6330 /// ],
6331 /// "type": [
6332 /// "boolean",
6333 /// "null"
6334 /// ]
6335 /// },
6336 /// "has_associated_categories": {
6337 /// "examples": [
6338 /// false
6339 /// ],
6340 /// "type": [
6341 /// "boolean",
6342 /// "null"
6343 /// ]
6344 /// },
6345 /// "has_associated_merchants": {
6346 /// "examples": [
6347 /// false
6348 /// ],
6349 /// "type": [
6350 /// "boolean",
6351 /// "null"
6352 /// ]
6353 /// },
6354 /// "has_associated_scheduled_payments": {
6355 /// "examples": [
6356 /// false
6357 /// ],
6358 /// "type": [
6359 /// "boolean",
6360 /// "null"
6361 /// ]
6362 /// },
6363 /// "has_associated_transactions": {
6364 /// "examples": [
6365 /// true
6366 /// ],
6367 /// "type": [
6368 /// "boolean",
6369 /// "null"
6370 /// ]
6371 /// },
6372 /// "has_been_displayed": {
6373 /// "examples": [
6374 /// true
6375 /// ],
6376 /// "type": [
6377 /// "boolean",
6378 /// "null"
6379 /// ]
6380 /// },
6381 /// "is_dismissed": {
6382 /// "examples": [
6383 /// false
6384 /// ],
6385 /// "type": [
6386 /// "boolean",
6387 /// "null"
6388 /// ]
6389 /// },
6390 /// "micro_call_to_action": {
6391 /// "examples": [
6392 /// "Learn more"
6393 /// ],
6394 /// "type": [
6395 /// "string",
6396 /// "null"
6397 /// ]
6398 /// },
6399 /// "micro_description": {
6400 /// "examples": [
6401 /// "Netflix charged you $5.00 more this month than normal."
6402 /// ],
6403 /// "type": [
6404 /// "string",
6405 /// "null"
6406 /// ]
6407 /// },
6408 /// "micro_title": {
6409 /// "examples": [
6410 /// "Price increase"
6411 /// ],
6412 /// "type": [
6413 /// "string",
6414 /// "null"
6415 /// ]
6416 /// },
6417 /// "template": {
6418 /// "examples": [
6419 /// "SubscriptionPriceIncrease"
6420 /// ],
6421 /// "type": [
6422 /// "string",
6423 /// "null"
6424 /// ]
6425 /// },
6426 /// "title": {
6427 /// "examples": [
6428 /// "Price increase"
6429 /// ],
6430 /// "type": [
6431 /// "string",
6432 /// "null"
6433 /// ]
6434 /// },
6435 /// "updated_at": {
6436 /// "examples": [
6437 /// "2022-01-12T18:16:51Z"
6438 /// ],
6439 /// "type": [
6440 /// "string",
6441 /// "null"
6442 /// ]
6443 /// },
6444 /// "user_guid": {
6445 /// "examples": [
6446 /// "USR-1234-abcd"
6447 /// ],
6448 /// "type": "string"
6449 /// },
6450 /// "user_id": {
6451 /// "examples": [
6452 /// "user-partner-defined-1234"
6453 /// ]
6454 /// }
6455 /// }
6456 ///}
6457 /// ```
6458 /// </details>
6459 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
6460 pub struct InsightResponse {
6461 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
6462 pub active_at: ::std::option::Option<::std::string::String>,
6463 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
6464 pub client_guid: ::std::option::Option<::std::string::String>,
6465 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
6466 pub created_at: ::std::option::Option<::std::string::String>,
6467 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
6468 pub cta_clicked_at: ::std::option::Option<::std::string::String>,
6469 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
6470 pub description: ::std::option::Option<::std::string::String>,
6471 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
6472 pub guid: ::std::option::Option<::std::string::String>,
6473 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
6474 pub has_associated_accounts: ::std::option::Option<bool>,
6475 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
6476 pub has_associated_categories: ::std::option::Option<bool>,
6477 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
6478 pub has_associated_merchants: ::std::option::Option<bool>,
6479 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
6480 pub has_associated_scheduled_payments: ::std::option::Option<bool>,
6481 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
6482 pub has_associated_transactions: ::std::option::Option<bool>,
6483 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
6484 pub has_been_displayed: ::std::option::Option<bool>,
6485 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
6486 pub is_dismissed: ::std::option::Option<bool>,
6487 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
6488 pub micro_call_to_action: ::std::option::Option<::std::string::String>,
6489 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
6490 pub micro_description: ::std::option::Option<::std::string::String>,
6491 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
6492 pub micro_title: ::std::option::Option<::std::string::String>,
6493 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
6494 pub template: ::std::option::Option<::std::string::String>,
6495 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
6496 pub title: ::std::option::Option<::std::string::String>,
6497 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
6498 pub updated_at: ::std::option::Option<::std::string::String>,
6499 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
6500 pub user_guid: ::std::option::Option<::std::string::String>,
6501 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
6502 pub user_id: ::std::option::Option<::serde_json::Value>,
6503 }
6504
6505 impl ::std::convert::From<&InsightResponse> for InsightResponse {
6506 fn from(value: &InsightResponse) -> Self {
6507 value.clone()
6508 }
6509 }
6510
6511 impl ::std::default::Default for InsightResponse {
6512 fn default() -> Self {
6513 Self {
6514 active_at: Default::default(),
6515 client_guid: Default::default(),
6516 created_at: Default::default(),
6517 cta_clicked_at: Default::default(),
6518 description: Default::default(),
6519 guid: Default::default(),
6520 has_associated_accounts: Default::default(),
6521 has_associated_categories: Default::default(),
6522 has_associated_merchants: Default::default(),
6523 has_associated_scheduled_payments: Default::default(),
6524 has_associated_transactions: Default::default(),
6525 has_been_displayed: Default::default(),
6526 is_dismissed: Default::default(),
6527 micro_call_to_action: Default::default(),
6528 micro_description: Default::default(),
6529 micro_title: Default::default(),
6530 template: Default::default(),
6531 title: Default::default(),
6532 updated_at: Default::default(),
6533 user_guid: Default::default(),
6534 user_id: Default::default(),
6535 }
6536 }
6537 }
6538
6539 ///`InsightResponseBody`
6540 ///
6541 /// <details><summary>JSON schema</summary>
6542 ///
6543 /// ```json
6544 ///{
6545 /// "type": "object",
6546 /// "properties": {
6547 /// "insight": {
6548 /// "$ref": "#/components/schemas/InsightResponse"
6549 /// }
6550 /// }
6551 ///}
6552 /// ```
6553 /// </details>
6554 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
6555 pub struct InsightResponseBody {
6556 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
6557 pub insight: ::std::option::Option<InsightResponse>,
6558 }
6559
6560 impl ::std::convert::From<&InsightResponseBody> for InsightResponseBody {
6561 fn from(value: &InsightResponseBody) -> Self {
6562 value.clone()
6563 }
6564 }
6565
6566 impl ::std::default::Default for InsightResponseBody {
6567 fn default() -> Self {
6568 Self {
6569 insight: Default::default(),
6570 }
6571 }
6572 }
6573
6574 ///`InsightUpdateRequest`
6575 ///
6576 /// <details><summary>JSON schema</summary>
6577 ///
6578 /// ```json
6579 ///{
6580 /// "properties": {
6581 /// "has_been_displayed": {
6582 /// "examples": [
6583 /// false
6584 /// ],
6585 /// "type": "boolean"
6586 /// },
6587 /// "is_dismissed": {
6588 /// "examples": [
6589 /// false
6590 /// ],
6591 /// "type": "boolean"
6592 /// }
6593 /// }
6594 ///}
6595 /// ```
6596 /// </details>
6597 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
6598 pub struct InsightUpdateRequest {
6599 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
6600 pub has_been_displayed: ::std::option::Option<bool>,
6601 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
6602 pub is_dismissed: ::std::option::Option<bool>,
6603 }
6604
6605 impl ::std::convert::From<&InsightUpdateRequest> for InsightUpdateRequest {
6606 fn from(value: &InsightUpdateRequest) -> Self {
6607 value.clone()
6608 }
6609 }
6610
6611 impl ::std::default::Default for InsightUpdateRequest {
6612 fn default() -> Self {
6613 Self {
6614 has_been_displayed: Default::default(),
6615 is_dismissed: Default::default(),
6616 }
6617 }
6618 }
6619
6620 ///`InsightUpdateRequestBody`
6621 ///
6622 /// <details><summary>JSON schema</summary>
6623 ///
6624 /// ```json
6625 ///{
6626 /// "type": "object",
6627 /// "properties": {
6628 /// "insight": {
6629 /// "$ref": "#/components/schemas/InsightUpdateRequest"
6630 /// }
6631 /// }
6632 ///}
6633 /// ```
6634 /// </details>
6635 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
6636 pub struct InsightUpdateRequestBody {
6637 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
6638 pub insight: ::std::option::Option<InsightUpdateRequest>,
6639 }
6640
6641 impl ::std::convert::From<&InsightUpdateRequestBody> for InsightUpdateRequestBody {
6642 fn from(value: &InsightUpdateRequestBody) -> Self {
6643 value.clone()
6644 }
6645 }
6646
6647 impl ::std::default::Default for InsightUpdateRequestBody {
6648 fn default() -> Self {
6649 Self {
6650 insight: Default::default(),
6651 }
6652 }
6653 }
6654
6655 ///`InsightsResponseBody`
6656 ///
6657 /// <details><summary>JSON schema</summary>
6658 ///
6659 /// ```json
6660 ///{
6661 /// "type": "object",
6662 /// "properties": {
6663 /// "insights": {
6664 /// "type": "array",
6665 /// "items": {
6666 /// "$ref": "#/components/schemas/InsightResponse"
6667 /// }
6668 /// },
6669 /// "pagination": {
6670 /// "$ref": "#/components/schemas/PaginationResponse"
6671 /// }
6672 /// }
6673 ///}
6674 /// ```
6675 /// </details>
6676 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
6677 pub struct InsightsResponseBody {
6678 #[serde(default, skip_serializing_if = "::std::vec::Vec::is_empty")]
6679 pub insights: ::std::vec::Vec<InsightResponse>,
6680 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
6681 pub pagination: ::std::option::Option<PaginationResponse>,
6682 }
6683
6684 impl ::std::convert::From<&InsightsResponseBody> for InsightsResponseBody {
6685 fn from(value: &InsightsResponseBody) -> Self {
6686 value.clone()
6687 }
6688 }
6689
6690 impl ::std::default::Default for InsightsResponseBody {
6691 fn default() -> Self {
6692 Self {
6693 insights: Default::default(),
6694 pagination: Default::default(),
6695 }
6696 }
6697 }
6698
6699 ///`InstitutionResponse`
6700 ///
6701 /// <details><summary>JSON schema</summary>
6702 ///
6703 /// ```json
6704 ///{
6705 /// "type": "object",
6706 /// "properties": {
6707 /// "code": {
6708 /// "examples": [
6709 /// "mxbank"
6710 /// ],
6711 /// "type": [
6712 /// "string",
6713 /// "null"
6714 /// ]
6715 /// },
6716 /// "forgot_password_url": {
6717 /// "examples": [
6718 /// "https://example.url.mxbank.com/forgot-password"
6719 /// ],
6720 /// "type": [
6721 /// "string",
6722 /// "null"
6723 /// ]
6724 /// },
6725 /// "forgot_username_url": {
6726 /// "examples": [
6727 /// "https://example.url.mxbank.com/forgot-username"
6728 /// ],
6729 /// "type": [
6730 /// "string",
6731 /// "null"
6732 /// ]
6733 /// },
6734 /// "instructional_text": {
6735 /// "examples": [
6736 /// "Some instructional text <a href=\"https://example.url.mxbank.com/instructions\" id=\"instructional_text\">for end users</a>."
6737 /// ],
6738 /// "type": [
6739 /// "string",
6740 /// "null"
6741 /// ]
6742 /// },
6743 /// "instructional_text_steps": {
6744 /// "description": "An array of instructional steps that may contain
6745 /// html elements.",
6746 /// "examples": [
6747 /// [
6748 /// "Step 1: Do this.",
6749 /// "Step 2: Do that."
6750 /// ]
6751 /// ],
6752 /// "type": [
6753 /// "array",
6754 /// "null"
6755 /// ],
6756 /// "items": {
6757 /// "type": "string"
6758 /// }
6759 /// },
6760 /// "is_disabled_by_client": {
6761 /// "examples": [
6762 /// false
6763 /// ],
6764 /// "type": [
6765 /// "boolean",
6766 /// "null"
6767 /// ]
6768 /// },
6769 /// "iso_country_code": {
6770 /// "examples": [
6771 /// "US"
6772 /// ],
6773 /// "type": "string"
6774 /// },
6775 /// "medium_logo_url": {
6776 /// "examples": [
6777 /// "https://content.moneydesktop.com/storage/MD_Assets/Ipad%20Logos/100x100/default_100x100.png"
6778 /// ],
6779 /// "type": [
6780 /// "string",
6781 /// "null"
6782 /// ]
6783 /// },
6784 /// "name": {
6785 /// "examples": [
6786 /// "MX Bank"
6787 /// ],
6788 /// "type": [
6789 /// "string",
6790 /// "null"
6791 /// ]
6792 /// },
6793 /// "small_logo_url": {
6794 /// "examples": [
6795 /// "https://content.moneydesktop.com/storage/MD_Assets/Ipad%20Logos/50x50/default_50x50.png"
6796 /// ],
6797 /// "type": [
6798 /// "string",
6799 /// "null"
6800 /// ]
6801 /// },
6802 /// "supports_account_identification": {
6803 /// "examples": [
6804 /// true
6805 /// ],
6806 /// "type": [
6807 /// "boolean",
6808 /// "null"
6809 /// ]
6810 /// },
6811 /// "supports_account_statement": {
6812 /// "examples": [
6813 /// true
6814 /// ],
6815 /// "type": [
6816 /// "boolean",
6817 /// "null"
6818 /// ]
6819 /// },
6820 /// "supports_account_verification": {
6821 /// "examples": [
6822 /// true
6823 /// ],
6824 /// "type": [
6825 /// "boolean",
6826 /// "null"
6827 /// ]
6828 /// },
6829 /// "supports_oauth": {
6830 /// "examples": [
6831 /// true
6832 /// ],
6833 /// "type": [
6834 /// "boolean",
6835 /// "null"
6836 /// ]
6837 /// },
6838 /// "supports_tax_document": {
6839 /// "examples": [
6840 /// true
6841 /// ],
6842 /// "type": [
6843 /// "boolean",
6844 /// "null"
6845 /// ]
6846 /// },
6847 /// "supports_transaction_history": {
6848 /// "examples": [
6849 /// true
6850 /// ],
6851 /// "type": [
6852 /// "boolean",
6853 /// "null"
6854 /// ]
6855 /// },
6856 /// "trouble_signing_in_url": {
6857 /// "examples": [
6858 /// "https://example.url.mxbank.com/login-trouble"
6859 /// ],
6860 /// "type": [
6861 /// "string",
6862 /// "null"
6863 /// ]
6864 /// },
6865 /// "url": {
6866 /// "examples": [
6867 /// "https://www.mxbank.com"
6868 /// ],
6869 /// "type": [
6870 /// "string",
6871 /// "null"
6872 /// ]
6873 /// }
6874 /// }
6875 ///}
6876 /// ```
6877 /// </details>
6878 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
6879 pub struct InstitutionResponse {
6880 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
6881 pub code: ::std::option::Option<::std::string::String>,
6882 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
6883 pub forgot_password_url: ::std::option::Option<::std::string::String>,
6884 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
6885 pub forgot_username_url: ::std::option::Option<::std::string::String>,
6886 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
6887 pub instructional_text: ::std::option::Option<::std::string::String>,
6888 ///An array of instructional steps that may contain html elements.
6889 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
6890 pub instructional_text_steps: ::std::option::Option<::std::vec::Vec<::std::string::String>>,
6891 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
6892 pub is_disabled_by_client: ::std::option::Option<bool>,
6893 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
6894 pub iso_country_code: ::std::option::Option<::std::string::String>,
6895 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
6896 pub medium_logo_url: ::std::option::Option<::std::string::String>,
6897 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
6898 pub name: ::std::option::Option<::std::string::String>,
6899 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
6900 pub small_logo_url: ::std::option::Option<::std::string::String>,
6901 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
6902 pub supports_account_identification: ::std::option::Option<bool>,
6903 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
6904 pub supports_account_statement: ::std::option::Option<bool>,
6905 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
6906 pub supports_account_verification: ::std::option::Option<bool>,
6907 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
6908 pub supports_oauth: ::std::option::Option<bool>,
6909 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
6910 pub supports_tax_document: ::std::option::Option<bool>,
6911 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
6912 pub supports_transaction_history: ::std::option::Option<bool>,
6913 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
6914 pub trouble_signing_in_url: ::std::option::Option<::std::string::String>,
6915 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
6916 pub url: ::std::option::Option<::std::string::String>,
6917 }
6918
6919 impl ::std::convert::From<&InstitutionResponse> for InstitutionResponse {
6920 fn from(value: &InstitutionResponse) -> Self {
6921 value.clone()
6922 }
6923 }
6924
6925 impl ::std::default::Default for InstitutionResponse {
6926 fn default() -> Self {
6927 Self {
6928 code: Default::default(),
6929 forgot_password_url: Default::default(),
6930 forgot_username_url: Default::default(),
6931 instructional_text: Default::default(),
6932 instructional_text_steps: Default::default(),
6933 is_disabled_by_client: Default::default(),
6934 iso_country_code: Default::default(),
6935 medium_logo_url: Default::default(),
6936 name: Default::default(),
6937 small_logo_url: Default::default(),
6938 supports_account_identification: Default::default(),
6939 supports_account_statement: Default::default(),
6940 supports_account_verification: Default::default(),
6941 supports_oauth: Default::default(),
6942 supports_tax_document: Default::default(),
6943 supports_transaction_history: Default::default(),
6944 trouble_signing_in_url: Default::default(),
6945 url: Default::default(),
6946 }
6947 }
6948 }
6949
6950 ///`InstitutionResponseBody`
6951 ///
6952 /// <details><summary>JSON schema</summary>
6953 ///
6954 /// ```json
6955 ///{
6956 /// "type": "object",
6957 /// "properties": {
6958 /// "institution": {
6959 /// "$ref": "#/components/schemas/InstitutionResponse"
6960 /// }
6961 /// }
6962 ///}
6963 /// ```
6964 /// </details>
6965 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
6966 pub struct InstitutionResponseBody {
6967 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
6968 pub institution: ::std::option::Option<InstitutionResponse>,
6969 }
6970
6971 impl ::std::convert::From<&InstitutionResponseBody> for InstitutionResponseBody {
6972 fn from(value: &InstitutionResponseBody) -> Self {
6973 value.clone()
6974 }
6975 }
6976
6977 impl ::std::default::Default for InstitutionResponseBody {
6978 fn default() -> Self {
6979 Self {
6980 institution: Default::default(),
6981 }
6982 }
6983 }
6984
6985 ///`InstitutionsResponseBody`
6986 ///
6987 /// <details><summary>JSON schema</summary>
6988 ///
6989 /// ```json
6990 ///{
6991 /// "type": "object",
6992 /// "properties": {
6993 /// "institutions": {
6994 /// "type": "array",
6995 /// "items": {
6996 /// "$ref": "#/components/schemas/InstitutionResponse"
6997 /// }
6998 /// },
6999 /// "pagination": {
7000 /// "$ref": "#/components/schemas/PaginationResponse"
7001 /// }
7002 /// }
7003 ///}
7004 /// ```
7005 /// </details>
7006 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
7007 pub struct InstitutionsResponseBody {
7008 #[serde(default, skip_serializing_if = "::std::vec::Vec::is_empty")]
7009 pub institutions: ::std::vec::Vec<InstitutionResponse>,
7010 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7011 pub pagination: ::std::option::Option<PaginationResponse>,
7012 }
7013
7014 impl ::std::convert::From<&InstitutionsResponseBody> for InstitutionsResponseBody {
7015 fn from(value: &InstitutionsResponseBody) -> Self {
7016 value.clone()
7017 }
7018 }
7019
7020 impl ::std::default::Default for InstitutionsResponseBody {
7021 fn default() -> Self {
7022 Self {
7023 institutions: Default::default(),
7024 pagination: Default::default(),
7025 }
7026 }
7027 }
7028
7029 ///`InvestmentHoldingResponse`
7030 ///
7031 /// <details><summary>JSON schema</summary>
7032 ///
7033 /// ```json
7034 ///{
7035 /// "type": "object",
7036 /// "properties": {
7037 /// "account_guid": {
7038 /// "examples": [
7039 /// "ACT-06d7f44b-caae-0f6e-1384-01f52e75dcb1"
7040 /// ],
7041 /// "type": [
7042 /// "string",
7043 /// "null"
7044 /// ]
7045 /// },
7046 /// "cost_basis": {
7047 /// "examples": [
7048 /// 827
7049 /// ],
7050 /// "type": [
7051 /// "number",
7052 /// "null"
7053 /// ]
7054 /// },
7055 /// "coupon_yield": {
7056 /// "type": [
7057 /// "string",
7058 /// "null"
7059 /// ]
7060 /// },
7061 /// "created_at": {
7062 /// "examples": [
7063 /// "2015-04-13T18:01:23.000Z"
7064 /// ],
7065 /// "type": [
7066 /// "string",
7067 /// "null"
7068 /// ]
7069 /// },
7070 /// "currency_code": {
7071 /// "examples": [
7072 /// "USD"
7073 /// ],
7074 /// "type": [
7075 /// "string",
7076 /// "null"
7077 /// ]
7078 /// },
7079 /// "current_price": {
7080 /// "examples": [
7081 /// 15
7082 /// ],
7083 /// "type": [
7084 /// "number",
7085 /// "null"
7086 /// ]
7087 /// },
7088 /// "current_price_as_of": {
7089 /// "examples": [
7090 /// "2023-11-06T00:00:00Z"
7091 /// ],
7092 /// "type": [
7093 /// "string",
7094 /// "null"
7095 /// ]
7096 /// },
7097 /// "daily_change": {
7098 /// "examples": [
7099 /// 2.5
7100 /// ],
7101 /// "type": [
7102 /// "number",
7103 /// "null"
7104 /// ]
7105 /// },
7106 /// "description": {
7107 /// "examples": [
7108 /// "Guggenheim Defensive Equity ETF"
7109 /// ],
7110 /// "type": [
7111 /// "string",
7112 /// "null"
7113 /// ]
7114 /// },
7115 /// "expiration": {
7116 /// "type": [
7117 /// "string",
7118 /// "null"
7119 /// ]
7120 /// },
7121 /// "face_value": {
7122 /// "type": [
7123 /// "number",
7124 /// "null"
7125 /// ]
7126 /// },
7127 /// "frequency": {
7128 /// "type": [
7129 /// "string",
7130 /// "null"
7131 /// ]
7132 /// },
7133 /// "guid": {
7134 /// "examples": [
7135 /// "HOL-d65683e8-9eab-26bb-bcfd-ced159c9abe2"
7136 /// ],
7137 /// "type": [
7138 /// "string",
7139 /// "null"
7140 /// ]
7141 /// },
7142 /// "holding_type": {
7143 /// "examples": [
7144 /// "MUTUAL_FUND"
7145 /// ],
7146 /// "type": [
7147 /// "string",
7148 /// "null"
7149 /// ]
7150 /// },
7151 /// "issue_date": {
7152 /// "examples": [
7153 /// "2015-08-15"
7154 /// ],
7155 /// "type": [
7156 /// "string",
7157 /// "null"
7158 /// ]
7159 /// },
7160 /// "market_value": {
7161 /// "examples": [
7162 /// 989.5
7163 /// ],
7164 /// "type": [
7165 /// "number",
7166 /// "null"
7167 /// ]
7168 /// },
7169 /// "maturity_date": {
7170 /// "type": [
7171 /// "string",
7172 /// "null"
7173 /// ]
7174 /// },
7175 /// "percentage_change": {
7176 /// "examples": [
7177 /// 0.2
7178 /// ],
7179 /// "type": [
7180 /// "number",
7181 /// "null"
7182 /// ]
7183 /// },
7184 /// "purchase_price": {
7185 /// "examples": [
7186 /// 26.3
7187 /// ],
7188 /// "type": [
7189 /// "number",
7190 /// "null"
7191 /// ]
7192 /// },
7193 /// "put_or_call": {
7194 /// "type": [
7195 /// "string",
7196 /// "null"
7197 /// ]
7198 /// },
7199 /// "quantity": {
7200 /// "examples": [
7201 /// "5000.0"
7202 /// ],
7203 /// "type": [
7204 /// "string",
7205 /// "null"
7206 /// ]
7207 /// },
7208 /// "rate": {
7209 /// "type": [
7210 /// "number",
7211 /// "null"
7212 /// ]
7213 /// },
7214 /// "strike_price": {
7215 /// "type": [
7216 /// "number",
7217 /// "null"
7218 /// ]
7219 /// },
7220 /// "symbol": {
7221 /// "examples": [
7222 /// "DEF"
7223 /// ],
7224 /// "type": [
7225 /// "string",
7226 /// "null"
7227 /// ]
7228 /// },
7229 /// "term": {
7230 /// "type": [
7231 /// "string",
7232 /// "null"
7233 /// ]
7234 /// },
7235 /// "term_unit": {
7236 /// "type": [
7237 /// "string",
7238 /// "null"
7239 /// ]
7240 /// },
7241 /// "today_ugl_amount": {
7242 /// "examples": [
7243 /// 200
7244 /// ],
7245 /// "type": [
7246 /// "number",
7247 /// "null"
7248 /// ]
7249 /// },
7250 /// "today_ugl_percentage": {
7251 /// "examples": [
7252 /// 0.27
7253 /// ],
7254 /// "type": [
7255 /// "number",
7256 /// "null"
7257 /// ]
7258 /// },
7259 /// "total_ugl_amount": {
7260 /// "examples": [
7261 /// 20000
7262 /// ],
7263 /// "type": [
7264 /// "number",
7265 /// "null"
7266 /// ]
7267 /// },
7268 /// "total_ugl_percentage": {
7269 /// "examples": [
7270 /// 26.67
7271 /// ],
7272 /// "type": [
7273 /// "number",
7274 /// "null"
7275 /// ]
7276 /// },
7277 /// "unvested_quantity": {
7278 /// "type": [
7279 /// "number",
7280 /// "null"
7281 /// ]
7282 /// },
7283 /// "unvested_value": {
7284 /// "type": [
7285 /// "number",
7286 /// "null"
7287 /// ]
7288 /// },
7289 /// "user_guid": {
7290 /// "examples": [
7291 /// "USR-743e5d7f-1116-28fa-5de1-d3ba02e41d8d"
7292 /// ],
7293 /// "type": [
7294 /// "string",
7295 /// "null"
7296 /// ]
7297 /// },
7298 /// "vested_quantity": {
7299 /// "type": [
7300 /// "number",
7301 /// "null"
7302 /// ]
7303 /// },
7304 /// "vested_value": {
7305 /// "type": [
7306 /// "number",
7307 /// "null"
7308 /// ]
7309 /// },
7310 /// "vesting_end_date": {
7311 /// "type": [
7312 /// "string",
7313 /// "null"
7314 /// ]
7315 /// },
7316 /// "vesting_start_date": {
7317 /// "type": [
7318 /// "string",
7319 /// "null"
7320 /// ]
7321 /// }
7322 /// }
7323 ///}
7324 /// ```
7325 /// </details>
7326 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
7327 pub struct InvestmentHoldingResponse {
7328 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7329 pub account_guid: ::std::option::Option<::std::string::String>,
7330 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7331 pub cost_basis: ::std::option::Option<f64>,
7332 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7333 pub coupon_yield: ::std::option::Option<::std::string::String>,
7334 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7335 pub created_at: ::std::option::Option<::std::string::String>,
7336 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7337 pub currency_code: ::std::option::Option<::std::string::String>,
7338 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7339 pub current_price: ::std::option::Option<f64>,
7340 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7341 pub current_price_as_of: ::std::option::Option<::std::string::String>,
7342 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7343 pub daily_change: ::std::option::Option<f64>,
7344 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7345 pub description: ::std::option::Option<::std::string::String>,
7346 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7347 pub expiration: ::std::option::Option<::std::string::String>,
7348 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7349 pub face_value: ::std::option::Option<f64>,
7350 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7351 pub frequency: ::std::option::Option<::std::string::String>,
7352 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7353 pub guid: ::std::option::Option<::std::string::String>,
7354 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7355 pub holding_type: ::std::option::Option<::std::string::String>,
7356 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7357 pub issue_date: ::std::option::Option<::std::string::String>,
7358 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7359 pub market_value: ::std::option::Option<f64>,
7360 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7361 pub maturity_date: ::std::option::Option<::std::string::String>,
7362 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7363 pub percentage_change: ::std::option::Option<f64>,
7364 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7365 pub purchase_price: ::std::option::Option<f64>,
7366 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7367 pub put_or_call: ::std::option::Option<::std::string::String>,
7368 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7369 pub quantity: ::std::option::Option<::std::string::String>,
7370 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7371 pub rate: ::std::option::Option<f64>,
7372 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7373 pub strike_price: ::std::option::Option<f64>,
7374 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7375 pub symbol: ::std::option::Option<::std::string::String>,
7376 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7377 pub term: ::std::option::Option<::std::string::String>,
7378 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7379 pub term_unit: ::std::option::Option<::std::string::String>,
7380 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7381 pub today_ugl_amount: ::std::option::Option<f64>,
7382 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7383 pub today_ugl_percentage: ::std::option::Option<f64>,
7384 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7385 pub total_ugl_amount: ::std::option::Option<f64>,
7386 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7387 pub total_ugl_percentage: ::std::option::Option<f64>,
7388 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7389 pub unvested_quantity: ::std::option::Option<f64>,
7390 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7391 pub unvested_value: ::std::option::Option<f64>,
7392 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7393 pub user_guid: ::std::option::Option<::std::string::String>,
7394 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7395 pub vested_quantity: ::std::option::Option<f64>,
7396 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7397 pub vested_value: ::std::option::Option<f64>,
7398 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7399 pub vesting_end_date: ::std::option::Option<::std::string::String>,
7400 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7401 pub vesting_start_date: ::std::option::Option<::std::string::String>,
7402 }
7403
7404 impl ::std::convert::From<&InvestmentHoldingResponse> for InvestmentHoldingResponse {
7405 fn from(value: &InvestmentHoldingResponse) -> Self {
7406 value.clone()
7407 }
7408 }
7409
7410 impl ::std::default::Default for InvestmentHoldingResponse {
7411 fn default() -> Self {
7412 Self {
7413 account_guid: Default::default(),
7414 cost_basis: Default::default(),
7415 coupon_yield: Default::default(),
7416 created_at: Default::default(),
7417 currency_code: Default::default(),
7418 current_price: Default::default(),
7419 current_price_as_of: Default::default(),
7420 daily_change: Default::default(),
7421 description: Default::default(),
7422 expiration: Default::default(),
7423 face_value: Default::default(),
7424 frequency: Default::default(),
7425 guid: Default::default(),
7426 holding_type: Default::default(),
7427 issue_date: Default::default(),
7428 market_value: Default::default(),
7429 maturity_date: Default::default(),
7430 percentage_change: Default::default(),
7431 purchase_price: Default::default(),
7432 put_or_call: Default::default(),
7433 quantity: Default::default(),
7434 rate: Default::default(),
7435 strike_price: Default::default(),
7436 symbol: Default::default(),
7437 term: Default::default(),
7438 term_unit: Default::default(),
7439 today_ugl_amount: Default::default(),
7440 today_ugl_percentage: Default::default(),
7441 total_ugl_amount: Default::default(),
7442 total_ugl_percentage: Default::default(),
7443 unvested_quantity: Default::default(),
7444 unvested_value: Default::default(),
7445 user_guid: Default::default(),
7446 vested_quantity: Default::default(),
7447 vested_value: Default::default(),
7448 vesting_end_date: Default::default(),
7449 vesting_start_date: Default::default(),
7450 }
7451 }
7452 }
7453
7454 ///`InvestmentHoldingResponseBody`
7455 ///
7456 /// <details><summary>JSON schema</summary>
7457 ///
7458 /// ```json
7459 ///{
7460 /// "type": "object",
7461 /// "properties": {
7462 /// "investment_holding": {
7463 /// "$ref": "#/components/schemas/InvestmentHoldingResponse"
7464 /// }
7465 /// }
7466 ///}
7467 /// ```
7468 /// </details>
7469 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
7470 pub struct InvestmentHoldingResponseBody {
7471 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7472 pub investment_holding: ::std::option::Option<InvestmentHoldingResponse>,
7473 }
7474
7475 impl ::std::convert::From<&InvestmentHoldingResponseBody> for InvestmentHoldingResponseBody {
7476 fn from(value: &InvestmentHoldingResponseBody) -> Self {
7477 value.clone()
7478 }
7479 }
7480
7481 impl ::std::default::Default for InvestmentHoldingResponseBody {
7482 fn default() -> Self {
7483 Self {
7484 investment_holding: Default::default(),
7485 }
7486 }
7487 }
7488
7489 ///`InvestmentHoldingsDeactivation`
7490 ///
7491 /// <details><summary>JSON schema</summary>
7492 ///
7493 /// ```json
7494 ///{
7495 /// "properties": {
7496 /// "message": {
7497 /// "examples": [
7498 /// "Successfully deactivated user from billing"
7499 /// ]
7500 /// },
7501 /// "status": {
7502 /// "examples": [
7503 /// 200
7504 /// ]
7505 /// }
7506 /// }
7507 ///}
7508 /// ```
7509 /// </details>
7510 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
7511 pub struct InvestmentHoldingsDeactivation {
7512 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7513 pub message: ::std::option::Option<::serde_json::Value>,
7514 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7515 pub status: ::std::option::Option<::serde_json::Value>,
7516 }
7517
7518 impl ::std::convert::From<&InvestmentHoldingsDeactivation> for InvestmentHoldingsDeactivation {
7519 fn from(value: &InvestmentHoldingsDeactivation) -> Self {
7520 value.clone()
7521 }
7522 }
7523
7524 impl ::std::default::Default for InvestmentHoldingsDeactivation {
7525 fn default() -> Self {
7526 Self {
7527 message: Default::default(),
7528 status: Default::default(),
7529 }
7530 }
7531 }
7532
7533 ///`InvestmentHoldingsResponseBody`
7534 ///
7535 /// <details><summary>JSON schema</summary>
7536 ///
7537 /// ```json
7538 ///{
7539 /// "type": "object",
7540 /// "properties": {
7541 /// "investment_holdings": {
7542 /// "type": "array",
7543 /// "items": {
7544 /// "$ref": "#/components/schemas/InvestmentHoldingResponse"
7545 /// }
7546 /// },
7547 /// "pagination": {
7548 /// "$ref": "#/components/schemas/PaginationResponse"
7549 /// }
7550 /// }
7551 ///}
7552 /// ```
7553 /// </details>
7554 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
7555 pub struct InvestmentHoldingsResponseBody {
7556 #[serde(default, skip_serializing_if = "::std::vec::Vec::is_empty")]
7557 pub investment_holdings: ::std::vec::Vec<InvestmentHoldingResponse>,
7558 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7559 pub pagination: ::std::option::Option<PaginationResponse>,
7560 }
7561
7562 impl ::std::convert::From<&InvestmentHoldingsResponseBody> for InvestmentHoldingsResponseBody {
7563 fn from(value: &InvestmentHoldingsResponseBody) -> Self {
7564 value.clone()
7565 }
7566 }
7567
7568 impl ::std::default::Default for InvestmentHoldingsResponseBody {
7569 fn default() -> Self {
7570 Self {
7571 investment_holdings: Default::default(),
7572 pagination: Default::default(),
7573 }
7574 }
7575 }
7576
7577 ///`ManagedAccountCreateRequest`
7578 ///
7579 /// <details><summary>JSON schema</summary>
7580 ///
7581 /// ```json
7582 ///{
7583 /// "type": "object",
7584 /// "required": [
7585 /// "balance",
7586 /// "id",
7587 /// "name",
7588 /// "type"
7589 /// ],
7590 /// "properties": {
7591 /// "account_number": {
7592 /// "examples": [
7593 /// "5366"
7594 /// ],
7595 /// "type": "string"
7596 /// },
7597 /// "apr": {
7598 /// "examples": [
7599 /// 1
7600 /// ],
7601 /// "type": "number"
7602 /// },
7603 /// "apy": {
7604 /// "examples": [
7605 /// 1
7606 /// ],
7607 /// "type": "number"
7608 /// },
7609 /// "available_balance": {
7610 /// "examples": [
7611 /// 1000
7612 /// ],
7613 /// "type": "number"
7614 /// },
7615 /// "available_credit": {
7616 /// "examples": [
7617 /// 1000
7618 /// ],
7619 /// "type": "number"
7620 /// },
7621 /// "balance": {
7622 /// "examples": [
7623 /// 1000
7624 /// ],
7625 /// "type": "number"
7626 /// },
7627 /// "cash_surrender_value": {
7628 /// "examples": [
7629 /// 1000
7630 /// ],
7631 /// "type": "number"
7632 /// },
7633 /// "credit_limit": {
7634 /// "examples": [
7635 /// 100
7636 /// ],
7637 /// "type": "number"
7638 /// },
7639 /// "currency_code": {
7640 /// "examples": [
7641 /// "USD"
7642 /// ],
7643 /// "type": "string"
7644 /// },
7645 /// "day_payment_is_due": {
7646 /// "examples": [
7647 /// 20
7648 /// ],
7649 /// "type": "integer"
7650 /// },
7651 /// "death_benefit": {
7652 /// "examples": [
7653 /// 1000
7654 /// ],
7655 /// "type": "integer"
7656 /// },
7657 /// "id": {
7658 /// "examples": [
7659 /// "1040434698"
7660 /// ],
7661 /// "type": "string"
7662 /// },
7663 /// "interest_rate": {
7664 /// "examples": [
7665 /// 1
7666 /// ],
7667 /// "type": "number"
7668 /// },
7669 /// "is_closed": {
7670 /// "examples": [
7671 /// false
7672 /// ],
7673 /// "type": "boolean"
7674 /// },
7675 /// "is_hidden": {
7676 /// "examples": [
7677 /// false
7678 /// ],
7679 /// "type": "boolean"
7680 /// },
7681 /// "last_payment": {
7682 /// "examples": [
7683 /// 100
7684 /// ],
7685 /// "type": "number"
7686 /// },
7687 /// "last_payment_at": {
7688 /// "examples": [
7689 /// "2015-10-13T17:57:37.000Z"
7690 /// ],
7691 /// "type": "string"
7692 /// },
7693 /// "loan_amount": {
7694 /// "examples": [
7695 /// 1000
7696 /// ],
7697 /// "type": "number"
7698 /// },
7699 /// "matures_on": {
7700 /// "examples": [
7701 /// "2015-10-13T17:57:37.000Z"
7702 /// ],
7703 /// "type": "string"
7704 /// },
7705 /// "metadata": {
7706 /// "examples": [
7707 /// "some metadata"
7708 /// ],
7709 /// "type": "string"
7710 /// },
7711 /// "minimum_balance": {
7712 /// "examples": [
7713 /// 100
7714 /// ],
7715 /// "type": "number"
7716 /// },
7717 /// "minimum_payment": {
7718 /// "examples": [
7719 /// 10
7720 /// ],
7721 /// "type": "number"
7722 /// },
7723 /// "name": {
7724 /// "examples": [
7725 /// "Test account 2"
7726 /// ],
7727 /// "type": "string"
7728 /// },
7729 /// "nickname": {
7730 /// "examples": [
7731 /// "Swiss Account"
7732 /// ],
7733 /// "type": "string"
7734 /// },
7735 /// "original_balance": {
7736 /// "examples": [
7737 /// 10
7738 /// ],
7739 /// "type": "number"
7740 /// },
7741 /// "payment_due_at": {
7742 /// "examples": [
7743 /// "2015-10-13T17:57:37.000Z"
7744 /// ],
7745 /// "type": "string"
7746 /// },
7747 /// "payoff_balance": {
7748 /// "examples": [
7749 /// 10
7750 /// ],
7751 /// "type": "number"
7752 /// },
7753 /// "routing_number": {
7754 /// "examples": [
7755 /// "68899990000000"
7756 /// ],
7757 /// "type": "string"
7758 /// },
7759 /// "started_on": {
7760 /// "examples": [
7761 /// "2015-10-13T17:57:37.000Z"
7762 /// ],
7763 /// "type": "string"
7764 /// },
7765 /// "subtype": {
7766 /// "examples": [
7767 /// "NONE"
7768 /// ],
7769 /// "type": "string"
7770 /// },
7771 /// "type": {
7772 /// "examples": [
7773 /// "SAVINGS"
7774 /// ],
7775 /// "type": "string"
7776 /// }
7777 /// }
7778 ///}
7779 /// ```
7780 /// </details>
7781 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
7782 pub struct ManagedAccountCreateRequest {
7783 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7784 pub account_number: ::std::option::Option<::std::string::String>,
7785 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7786 pub apr: ::std::option::Option<f64>,
7787 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7788 pub apy: ::std::option::Option<f64>,
7789 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7790 pub available_balance: ::std::option::Option<f64>,
7791 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7792 pub available_credit: ::std::option::Option<f64>,
7793 pub balance: f64,
7794 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7795 pub cash_surrender_value: ::std::option::Option<f64>,
7796 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7797 pub credit_limit: ::std::option::Option<f64>,
7798 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7799 pub currency_code: ::std::option::Option<::std::string::String>,
7800 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7801 pub day_payment_is_due: ::std::option::Option<i64>,
7802 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7803 pub death_benefit: ::std::option::Option<i64>,
7804 pub id: ::std::string::String,
7805 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7806 pub interest_rate: ::std::option::Option<f64>,
7807 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7808 pub is_closed: ::std::option::Option<bool>,
7809 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7810 pub is_hidden: ::std::option::Option<bool>,
7811 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7812 pub last_payment: ::std::option::Option<f64>,
7813 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7814 pub last_payment_at: ::std::option::Option<::std::string::String>,
7815 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7816 pub loan_amount: ::std::option::Option<f64>,
7817 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7818 pub matures_on: ::std::option::Option<::std::string::String>,
7819 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7820 pub metadata: ::std::option::Option<::std::string::String>,
7821 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7822 pub minimum_balance: ::std::option::Option<f64>,
7823 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7824 pub minimum_payment: ::std::option::Option<f64>,
7825 pub name: ::std::string::String,
7826 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7827 pub nickname: ::std::option::Option<::std::string::String>,
7828 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7829 pub original_balance: ::std::option::Option<f64>,
7830 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7831 pub payment_due_at: ::std::option::Option<::std::string::String>,
7832 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7833 pub payoff_balance: ::std::option::Option<f64>,
7834 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7835 pub routing_number: ::std::option::Option<::std::string::String>,
7836 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7837 pub started_on: ::std::option::Option<::std::string::String>,
7838 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7839 pub subtype: ::std::option::Option<::std::string::String>,
7840 #[serde(rename = "type")]
7841 pub type_: ::std::string::String,
7842 }
7843
7844 impl ::std::convert::From<&ManagedAccountCreateRequest> for ManagedAccountCreateRequest {
7845 fn from(value: &ManagedAccountCreateRequest) -> Self {
7846 value.clone()
7847 }
7848 }
7849
7850 ///`ManagedAccountCreateRequestBody`
7851 ///
7852 /// <details><summary>JSON schema</summary>
7853 ///
7854 /// ```json
7855 ///{
7856 /// "type": "object",
7857 /// "properties": {
7858 /// "account": {
7859 /// "$ref": "#/components/schemas/ManagedAccountCreateRequest"
7860 /// }
7861 /// }
7862 ///}
7863 /// ```
7864 /// </details>
7865 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
7866 pub struct ManagedAccountCreateRequestBody {
7867 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
7868 pub account: ::std::option::Option<ManagedAccountCreateRequest>,
7869 }
7870
7871 impl ::std::convert::From<&ManagedAccountCreateRequestBody> for ManagedAccountCreateRequestBody {
7872 fn from(value: &ManagedAccountCreateRequestBody) -> Self {
7873 value.clone()
7874 }
7875 }
7876
7877 impl ::std::default::Default for ManagedAccountCreateRequestBody {
7878 fn default() -> Self {
7879 Self {
7880 account: Default::default(),
7881 }
7882 }
7883 }
7884
7885 ///`ManagedAccountUpdateRequest`
7886 ///
7887 /// <details><summary>JSON schema</summary>
7888 ///
7889 /// ```json
7890 ///{
7891 /// "type": "object",
7892 /// "properties": {
7893 /// "account_number": {
7894 /// "examples": [
7895 /// "5366"
7896 /// ],
7897 /// "type": "string"
7898 /// },
7899 /// "apr": {
7900 /// "examples": [
7901 /// 1
7902 /// ],
7903 /// "type": "number"
7904 /// },
7905 /// "apy": {
7906 /// "examples": [
7907 /// 1
7908 /// ],
7909 /// "type": "number"
7910 /// },
7911 /// "available_balance": {
7912 /// "examples": [
7913 /// 1000
7914 /// ],
7915 /// "type": "number"
7916 /// },
7917 /// "available_credit": {
7918 /// "examples": [
7919 /// 1000
7920 /// ],
7921 /// "type": "number"
7922 /// },
7923 /// "balance": {
7924 /// "examples": [
7925 /// 1000
7926 /// ],
7927 /// "type": "number"
7928 /// },
7929 /// "cash_surrender_value": {
7930 /// "examples": [
7931 /// 1000
7932 /// ],
7933 /// "type": "number"
7934 /// },
7935 /// "credit_limit": {
7936 /// "examples": [
7937 /// 100
7938 /// ],
7939 /// "type": "number"
7940 /// },
7941 /// "currency_code": {
7942 /// "examples": [
7943 /// "USD"
7944 /// ],
7945 /// "type": "string"
7946 /// },
7947 /// "day_payment_is_due": {
7948 /// "examples": [
7949 /// 20
7950 /// ],
7951 /// "type": "integer"
7952 /// },
7953 /// "death_benefit": {
7954 /// "examples": [
7955 /// 1000
7956 /// ],
7957 /// "type": "integer"
7958 /// },
7959 /// "id": {
7960 /// "examples": [
7961 /// "1040434698"
7962 /// ],
7963 /// "type": "string"
7964 /// },
7965 /// "interest_rate": {
7966 /// "examples": [
7967 /// 1
7968 /// ],
7969 /// "type": "number"
7970 /// },
7971 /// "is_closed": {
7972 /// "examples": [
7973 /// false
7974 /// ],
7975 /// "type": "boolean"
7976 /// },
7977 /// "is_hidden": {
7978 /// "examples": [
7979 /// false
7980 /// ],
7981 /// "type": "boolean"
7982 /// },
7983 /// "last_payment": {
7984 /// "examples": [
7985 /// 100
7986 /// ],
7987 /// "type": "number"
7988 /// },
7989 /// "last_payment_at": {
7990 /// "examples": [
7991 /// "2015-10-13T17:57:37.000Z"
7992 /// ],
7993 /// "type": "string"
7994 /// },
7995 /// "loan_amount": {
7996 /// "examples": [
7997 /// 1000
7998 /// ],
7999 /// "type": "number"
8000 /// },
8001 /// "matures_on": {
8002 /// "examples": [
8003 /// "2015-10-13T17:57:37.000Z"
8004 /// ],
8005 /// "type": "string"
8006 /// },
8007 /// "metadata": {
8008 /// "examples": [
8009 /// "some metadata"
8010 /// ],
8011 /// "type": "string"
8012 /// },
8013 /// "minimum_balance": {
8014 /// "examples": [
8015 /// 100
8016 /// ],
8017 /// "type": "number"
8018 /// },
8019 /// "minimum_payment": {
8020 /// "examples": [
8021 /// 10
8022 /// ],
8023 /// "type": "number"
8024 /// },
8025 /// "name": {
8026 /// "examples": [
8027 /// "Test account 2"
8028 /// ],
8029 /// "type": "string"
8030 /// },
8031 /// "nickname": {
8032 /// "examples": [
8033 /// "Swiss Account"
8034 /// ],
8035 /// "type": "string"
8036 /// },
8037 /// "original_balance": {
8038 /// "examples": [
8039 /// 10
8040 /// ],
8041 /// "type": "number"
8042 /// },
8043 /// "payment_due_at": {
8044 /// "examples": [
8045 /// "2015-10-13T17:57:37.000Z"
8046 /// ],
8047 /// "type": "string"
8048 /// },
8049 /// "payoff_balance": {
8050 /// "examples": [
8051 /// 10
8052 /// ],
8053 /// "type": "number"
8054 /// },
8055 /// "routing_number": {
8056 /// "examples": [
8057 /// "68899990000000"
8058 /// ],
8059 /// "type": "string"
8060 /// },
8061 /// "started_on": {
8062 /// "examples": [
8063 /// "2015-10-13T17:57:37.000Z"
8064 /// ],
8065 /// "type": "string"
8066 /// },
8067 /// "subtype": {
8068 /// "examples": [
8069 /// "NONE"
8070 /// ],
8071 /// "type": "string"
8072 /// },
8073 /// "type": {
8074 /// "examples": [
8075 /// "SAVINGS"
8076 /// ],
8077 /// "type": "string"
8078 /// }
8079 /// }
8080 ///}
8081 /// ```
8082 /// </details>
8083 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
8084 pub struct ManagedAccountUpdateRequest {
8085 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8086 pub account_number: ::std::option::Option<::std::string::String>,
8087 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8088 pub apr: ::std::option::Option<f64>,
8089 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8090 pub apy: ::std::option::Option<f64>,
8091 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8092 pub available_balance: ::std::option::Option<f64>,
8093 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8094 pub available_credit: ::std::option::Option<f64>,
8095 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8096 pub balance: ::std::option::Option<f64>,
8097 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8098 pub cash_surrender_value: ::std::option::Option<f64>,
8099 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8100 pub credit_limit: ::std::option::Option<f64>,
8101 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8102 pub currency_code: ::std::option::Option<::std::string::String>,
8103 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8104 pub day_payment_is_due: ::std::option::Option<i64>,
8105 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8106 pub death_benefit: ::std::option::Option<i64>,
8107 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8108 pub id: ::std::option::Option<::std::string::String>,
8109 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8110 pub interest_rate: ::std::option::Option<f64>,
8111 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8112 pub is_closed: ::std::option::Option<bool>,
8113 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8114 pub is_hidden: ::std::option::Option<bool>,
8115 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8116 pub last_payment: ::std::option::Option<f64>,
8117 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8118 pub last_payment_at: ::std::option::Option<::std::string::String>,
8119 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8120 pub loan_amount: ::std::option::Option<f64>,
8121 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8122 pub matures_on: ::std::option::Option<::std::string::String>,
8123 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8124 pub metadata: ::std::option::Option<::std::string::String>,
8125 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8126 pub minimum_balance: ::std::option::Option<f64>,
8127 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8128 pub minimum_payment: ::std::option::Option<f64>,
8129 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8130 pub name: ::std::option::Option<::std::string::String>,
8131 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8132 pub nickname: ::std::option::Option<::std::string::String>,
8133 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8134 pub original_balance: ::std::option::Option<f64>,
8135 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8136 pub payment_due_at: ::std::option::Option<::std::string::String>,
8137 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8138 pub payoff_balance: ::std::option::Option<f64>,
8139 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8140 pub routing_number: ::std::option::Option<::std::string::String>,
8141 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8142 pub started_on: ::std::option::Option<::std::string::String>,
8143 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8144 pub subtype: ::std::option::Option<::std::string::String>,
8145 #[serde(
8146 rename = "type",
8147 default,
8148 skip_serializing_if = "::std::option::Option::is_none"
8149 )]
8150 pub type_: ::std::option::Option<::std::string::String>,
8151 }
8152
8153 impl ::std::convert::From<&ManagedAccountUpdateRequest> for ManagedAccountUpdateRequest {
8154 fn from(value: &ManagedAccountUpdateRequest) -> Self {
8155 value.clone()
8156 }
8157 }
8158
8159 impl ::std::default::Default for ManagedAccountUpdateRequest {
8160 fn default() -> Self {
8161 Self {
8162 account_number: Default::default(),
8163 apr: Default::default(),
8164 apy: Default::default(),
8165 available_balance: Default::default(),
8166 available_credit: Default::default(),
8167 balance: Default::default(),
8168 cash_surrender_value: Default::default(),
8169 credit_limit: Default::default(),
8170 currency_code: Default::default(),
8171 day_payment_is_due: Default::default(),
8172 death_benefit: Default::default(),
8173 id: Default::default(),
8174 interest_rate: Default::default(),
8175 is_closed: Default::default(),
8176 is_hidden: Default::default(),
8177 last_payment: Default::default(),
8178 last_payment_at: Default::default(),
8179 loan_amount: Default::default(),
8180 matures_on: Default::default(),
8181 metadata: Default::default(),
8182 minimum_balance: Default::default(),
8183 minimum_payment: Default::default(),
8184 name: Default::default(),
8185 nickname: Default::default(),
8186 original_balance: Default::default(),
8187 payment_due_at: Default::default(),
8188 payoff_balance: Default::default(),
8189 routing_number: Default::default(),
8190 started_on: Default::default(),
8191 subtype: Default::default(),
8192 type_: Default::default(),
8193 }
8194 }
8195 }
8196
8197 ///`ManagedAccountUpdateRequestBody`
8198 ///
8199 /// <details><summary>JSON schema</summary>
8200 ///
8201 /// ```json
8202 ///{
8203 /// "type": "object",
8204 /// "properties": {
8205 /// "account": {
8206 /// "$ref": "#/components/schemas/ManagedAccountUpdateRequest"
8207 /// }
8208 /// }
8209 ///}
8210 /// ```
8211 /// </details>
8212 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
8213 pub struct ManagedAccountUpdateRequestBody {
8214 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8215 pub account: ::std::option::Option<ManagedAccountUpdateRequest>,
8216 }
8217
8218 impl ::std::convert::From<&ManagedAccountUpdateRequestBody> for ManagedAccountUpdateRequestBody {
8219 fn from(value: &ManagedAccountUpdateRequestBody) -> Self {
8220 value.clone()
8221 }
8222 }
8223
8224 impl ::std::default::Default for ManagedAccountUpdateRequestBody {
8225 fn default() -> Self {
8226 Self {
8227 account: Default::default(),
8228 }
8229 }
8230 }
8231
8232 ///`ManagedMemberCreateRequest`
8233 ///
8234 /// <details><summary>JSON schema</summary>
8235 ///
8236 /// ```json
8237 ///{
8238 /// "type": "object",
8239 /// "required": [
8240 /// "institution_code"
8241 /// ],
8242 /// "properties": {
8243 /// "id": {
8244 /// "examples": [
8245 /// "member123"
8246 /// ],
8247 /// "type": "string"
8248 /// },
8249 /// "institution_code": {
8250 /// "examples": [
8251 /// "mxbank"
8252 /// ],
8253 /// "type": "string"
8254 /// },
8255 /// "metadata": {
8256 /// "examples": [
8257 /// "some metadata"
8258 /// ],
8259 /// "type": "string"
8260 /// },
8261 /// "name": {
8262 /// "examples": [
8263 /// "MX Bank"
8264 /// ],
8265 /// "type": "string"
8266 /// }
8267 /// }
8268 ///}
8269 /// ```
8270 /// </details>
8271 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
8272 pub struct ManagedMemberCreateRequest {
8273 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8274 pub id: ::std::option::Option<::std::string::String>,
8275 pub institution_code: ::std::string::String,
8276 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8277 pub metadata: ::std::option::Option<::std::string::String>,
8278 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8279 pub name: ::std::option::Option<::std::string::String>,
8280 }
8281
8282 impl ::std::convert::From<&ManagedMemberCreateRequest> for ManagedMemberCreateRequest {
8283 fn from(value: &ManagedMemberCreateRequest) -> Self {
8284 value.clone()
8285 }
8286 }
8287
8288 ///`ManagedMemberCreateRequestBody`
8289 ///
8290 /// <details><summary>JSON schema</summary>
8291 ///
8292 /// ```json
8293 ///{
8294 /// "type": "object",
8295 /// "properties": {
8296 /// "member": {
8297 /// "$ref": "#/components/schemas/ManagedMemberCreateRequest"
8298 /// }
8299 /// }
8300 ///}
8301 /// ```
8302 /// </details>
8303 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
8304 pub struct ManagedMemberCreateRequestBody {
8305 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8306 pub member: ::std::option::Option<ManagedMemberCreateRequest>,
8307 }
8308
8309 impl ::std::convert::From<&ManagedMemberCreateRequestBody> for ManagedMemberCreateRequestBody {
8310 fn from(value: &ManagedMemberCreateRequestBody) -> Self {
8311 value.clone()
8312 }
8313 }
8314
8315 impl ::std::default::Default for ManagedMemberCreateRequestBody {
8316 fn default() -> Self {
8317 Self {
8318 member: Default::default(),
8319 }
8320 }
8321 }
8322
8323 ///`ManagedMemberUpdateRequest`
8324 ///
8325 /// <details><summary>JSON schema</summary>
8326 ///
8327 /// ```json
8328 ///{
8329 /// "type": "object",
8330 /// "properties": {
8331 /// "id": {
8332 /// "examples": [
8333 /// "member123"
8334 /// ],
8335 /// "type": "string"
8336 /// },
8337 /// "metadata": {
8338 /// "examples": [
8339 /// "some metadata"
8340 /// ],
8341 /// "type": "string"
8342 /// },
8343 /// "name": {
8344 /// "examples": [
8345 /// "MX Bank"
8346 /// ],
8347 /// "type": "string"
8348 /// }
8349 /// }
8350 ///}
8351 /// ```
8352 /// </details>
8353 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
8354 pub struct ManagedMemberUpdateRequest {
8355 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8356 pub id: ::std::option::Option<::std::string::String>,
8357 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8358 pub metadata: ::std::option::Option<::std::string::String>,
8359 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8360 pub name: ::std::option::Option<::std::string::String>,
8361 }
8362
8363 impl ::std::convert::From<&ManagedMemberUpdateRequest> for ManagedMemberUpdateRequest {
8364 fn from(value: &ManagedMemberUpdateRequest) -> Self {
8365 value.clone()
8366 }
8367 }
8368
8369 impl ::std::default::Default for ManagedMemberUpdateRequest {
8370 fn default() -> Self {
8371 Self {
8372 id: Default::default(),
8373 metadata: Default::default(),
8374 name: Default::default(),
8375 }
8376 }
8377 }
8378
8379 ///`ManagedMemberUpdateRequestBody`
8380 ///
8381 /// <details><summary>JSON schema</summary>
8382 ///
8383 /// ```json
8384 ///{
8385 /// "type": "object",
8386 /// "properties": {
8387 /// "member": {
8388 /// "$ref": "#/components/schemas/ManagedMemberUpdateRequest"
8389 /// }
8390 /// }
8391 ///}
8392 /// ```
8393 /// </details>
8394 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
8395 pub struct ManagedMemberUpdateRequestBody {
8396 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8397 pub member: ::std::option::Option<ManagedMemberUpdateRequest>,
8398 }
8399
8400 impl ::std::convert::From<&ManagedMemberUpdateRequestBody> for ManagedMemberUpdateRequestBody {
8401 fn from(value: &ManagedMemberUpdateRequestBody) -> Self {
8402 value.clone()
8403 }
8404 }
8405
8406 impl ::std::default::Default for ManagedMemberUpdateRequestBody {
8407 fn default() -> Self {
8408 Self {
8409 member: Default::default(),
8410 }
8411 }
8412 }
8413
8414 ///`ManagedTransactionCreateRequest`
8415 ///
8416 /// <details><summary>JSON schema</summary>
8417 ///
8418 /// ```json
8419 ///{
8420 /// "type": "object",
8421 /// "required": [
8422 /// "amount",
8423 /// "description",
8424 /// "posted_at",
8425 /// "status",
8426 /// "transacted_at",
8427 /// "type"
8428 /// ],
8429 /// "properties": {
8430 /// "amount": {
8431 /// "examples": [
8432 /// "61.11"
8433 /// ],
8434 /// "type": "string"
8435 /// },
8436 /// "category": {
8437 /// "examples": [
8438 /// "Groceries"
8439 /// ],
8440 /// "type": "string"
8441 /// },
8442 /// "check_number_string": {
8443 /// "examples": [
8444 /// "6812"
8445 /// ],
8446 /// "type": "string"
8447 /// },
8448 /// "currency_code": {
8449 /// "examples": [
8450 /// "USD"
8451 /// ],
8452 /// "type": "string"
8453 /// },
8454 /// "description": {
8455 /// "examples": [
8456 /// "Whole foods"
8457 /// ],
8458 /// "type": "string"
8459 /// },
8460 /// "id": {
8461 /// "examples": [
8462 /// "transaction-265abee9-889b-af6a-c69b-25157db2bdd9"
8463 /// ],
8464 /// "type": "string"
8465 /// },
8466 /// "is_international": {
8467 /// "examples": [
8468 /// false
8469 /// ],
8470 /// "type": "boolean"
8471 /// },
8472 /// "latitude": {
8473 /// "examples": [
8474 /// -43.2075
8475 /// ],
8476 /// "type": "number"
8477 /// },
8478 /// "localized_description": {
8479 /// "examples": [
8480 /// "This is a localized_description"
8481 /// ],
8482 /// "type": "string"
8483 /// },
8484 /// "localized_memo": {
8485 /// "examples": [
8486 /// "This is a localized_memo"
8487 /// ],
8488 /// "type": "string"
8489 /// },
8490 /// "longitude": {
8491 /// "examples": [
8492 /// 139.691706
8493 /// ],
8494 /// "type": "number"
8495 /// },
8496 /// "memo": {
8497 /// "examples": [
8498 /// "This is a memo"
8499 /// ],
8500 /// "type": "string"
8501 /// },
8502 /// "merchant_category_code": {
8503 /// "examples": [
8504 /// 5411
8505 /// ],
8506 /// "type": "integer"
8507 /// },
8508 /// "merchant_guid": {
8509 /// "examples": [
8510 /// "MCH-7ed79542-884d-2b1b-dd74-501c5cc9d25b"
8511 /// ],
8512 /// "type": "string"
8513 /// },
8514 /// "merchant_location_guid": {
8515 /// "examples": [
8516 /// "MCL-00024e59-18b5-4d79-b879-2a7896726fea"
8517 /// ],
8518 /// "type": "string"
8519 /// },
8520 /// "metadata": {
8521 /// "examples": [
8522 /// "some metadata"
8523 /// ],
8524 /// "type": "string"
8525 /// },
8526 /// "posted_at": {
8527 /// "examples": [
8528 /// "2016-10-07T06:00:00.000Z"
8529 /// ],
8530 /// "type": "string"
8531 /// },
8532 /// "status": {
8533 /// "examples": [
8534 /// "POSTED"
8535 /// ],
8536 /// "type": "string"
8537 /// },
8538 /// "transacted_at": {
8539 /// "examples": [
8540 /// "2016-10-06T13:00:00.000Z"
8541 /// ],
8542 /// "type": "string"
8543 /// },
8544 /// "type": {
8545 /// "examples": [
8546 /// "DEBIT"
8547 /// ],
8548 /// "type": "string"
8549 /// }
8550 /// }
8551 ///}
8552 /// ```
8553 /// </details>
8554 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
8555 pub struct ManagedTransactionCreateRequest {
8556 pub amount: ::std::string::String,
8557 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8558 pub category: ::std::option::Option<::std::string::String>,
8559 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8560 pub check_number_string: ::std::option::Option<::std::string::String>,
8561 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8562 pub currency_code: ::std::option::Option<::std::string::String>,
8563 pub description: ::std::string::String,
8564 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8565 pub id: ::std::option::Option<::std::string::String>,
8566 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8567 pub is_international: ::std::option::Option<bool>,
8568 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8569 pub latitude: ::std::option::Option<f64>,
8570 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8571 pub localized_description: ::std::option::Option<::std::string::String>,
8572 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8573 pub localized_memo: ::std::option::Option<::std::string::String>,
8574 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8575 pub longitude: ::std::option::Option<f64>,
8576 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8577 pub memo: ::std::option::Option<::std::string::String>,
8578 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8579 pub merchant_category_code: ::std::option::Option<i64>,
8580 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8581 pub merchant_guid: ::std::option::Option<::std::string::String>,
8582 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8583 pub merchant_location_guid: ::std::option::Option<::std::string::String>,
8584 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8585 pub metadata: ::std::option::Option<::std::string::String>,
8586 pub posted_at: ::std::string::String,
8587 pub status: ::std::string::String,
8588 pub transacted_at: ::std::string::String,
8589 #[serde(rename = "type")]
8590 pub type_: ::std::string::String,
8591 }
8592
8593 impl ::std::convert::From<&ManagedTransactionCreateRequest> for ManagedTransactionCreateRequest {
8594 fn from(value: &ManagedTransactionCreateRequest) -> Self {
8595 value.clone()
8596 }
8597 }
8598
8599 ///`ManagedTransactionCreateRequestBody`
8600 ///
8601 /// <details><summary>JSON schema</summary>
8602 ///
8603 /// ```json
8604 ///{
8605 /// "type": "object",
8606 /// "properties": {
8607 /// "transaction": {
8608 /// "$ref": "#/components/schemas/ManagedTransactionCreateRequest"
8609 /// }
8610 /// }
8611 ///}
8612 /// ```
8613 /// </details>
8614 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
8615 pub struct ManagedTransactionCreateRequestBody {
8616 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8617 pub transaction: ::std::option::Option<ManagedTransactionCreateRequest>,
8618 }
8619
8620 impl ::std::convert::From<&ManagedTransactionCreateRequestBody>
8621 for ManagedTransactionCreateRequestBody
8622 {
8623 fn from(value: &ManagedTransactionCreateRequestBody) -> Self {
8624 value.clone()
8625 }
8626 }
8627
8628 impl ::std::default::Default for ManagedTransactionCreateRequestBody {
8629 fn default() -> Self {
8630 Self {
8631 transaction: Default::default(),
8632 }
8633 }
8634 }
8635
8636 ///`ManagedTransactionUpdateRequest`
8637 ///
8638 /// <details><summary>JSON schema</summary>
8639 ///
8640 /// ```json
8641 ///{
8642 /// "type": "object",
8643 /// "properties": {
8644 /// "amount": {
8645 /// "examples": [
8646 /// "61.11"
8647 /// ],
8648 /// "type": "string"
8649 /// },
8650 /// "category": {
8651 /// "examples": [
8652 /// "Groceries"
8653 /// ],
8654 /// "type": "string"
8655 /// },
8656 /// "check_number_string": {
8657 /// "examples": [
8658 /// "6812"
8659 /// ],
8660 /// "type": "string"
8661 /// },
8662 /// "currency_code": {
8663 /// "examples": [
8664 /// "USD"
8665 /// ],
8666 /// "type": "string"
8667 /// },
8668 /// "description": {
8669 /// "examples": [
8670 /// "Whole foods"
8671 /// ],
8672 /// "type": "string"
8673 /// },
8674 /// "id": {
8675 /// "examples": [
8676 /// "transaction-265abee9-889b-af6a-c69b-25157db2bdd9"
8677 /// ],
8678 /// "type": "string"
8679 /// },
8680 /// "is_international": {
8681 /// "examples": [
8682 /// false
8683 /// ],
8684 /// "type": "boolean"
8685 /// },
8686 /// "latitude": {
8687 /// "examples": [
8688 /// -43.2075
8689 /// ],
8690 /// "type": "number"
8691 /// },
8692 /// "localized_description": {
8693 /// "examples": [
8694 /// "This is a localized_description"
8695 /// ],
8696 /// "type": "string"
8697 /// },
8698 /// "localized_memo": {
8699 /// "examples": [
8700 /// "This is a localized_memo"
8701 /// ],
8702 /// "type": "string"
8703 /// },
8704 /// "longitude": {
8705 /// "examples": [
8706 /// 139.691706
8707 /// ],
8708 /// "type": "number"
8709 /// },
8710 /// "memo": {
8711 /// "examples": [
8712 /// "This is a memo"
8713 /// ],
8714 /// "type": "string"
8715 /// },
8716 /// "merchant_category_code": {
8717 /// "examples": [
8718 /// 5411
8719 /// ],
8720 /// "type": "integer"
8721 /// },
8722 /// "merchant_guid": {
8723 /// "examples": [
8724 /// "MCH-7ed79542-884d-2b1b-dd74-501c5cc9d25b"
8725 /// ],
8726 /// "type": "string"
8727 /// },
8728 /// "merchant_location_guid": {
8729 /// "examples": [
8730 /// "MCL-00024e59-18b5-4d79-b879-2a7896726fea"
8731 /// ],
8732 /// "type": "string"
8733 /// },
8734 /// "metadata": {
8735 /// "examples": [
8736 /// "some metadata"
8737 /// ],
8738 /// "type": "string"
8739 /// },
8740 /// "posted_at": {
8741 /// "examples": [
8742 /// "2016-10-07T06:00:00.000Z"
8743 /// ],
8744 /// "type": "string"
8745 /// },
8746 /// "status": {
8747 /// "examples": [
8748 /// "POSTED"
8749 /// ],
8750 /// "type": "string"
8751 /// },
8752 /// "transacted_at": {
8753 /// "examples": [
8754 /// "2016-10-06T13:00:00.000Z"
8755 /// ],
8756 /// "type": "string"
8757 /// },
8758 /// "type": {
8759 /// "examples": [
8760 /// "DEBIT"
8761 /// ],
8762 /// "type": "string"
8763 /// }
8764 /// }
8765 ///}
8766 /// ```
8767 /// </details>
8768 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
8769 pub struct ManagedTransactionUpdateRequest {
8770 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8771 pub amount: ::std::option::Option<::std::string::String>,
8772 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8773 pub category: ::std::option::Option<::std::string::String>,
8774 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8775 pub check_number_string: ::std::option::Option<::std::string::String>,
8776 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8777 pub currency_code: ::std::option::Option<::std::string::String>,
8778 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8779 pub description: ::std::option::Option<::std::string::String>,
8780 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8781 pub id: ::std::option::Option<::std::string::String>,
8782 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8783 pub is_international: ::std::option::Option<bool>,
8784 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8785 pub latitude: ::std::option::Option<f64>,
8786 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8787 pub localized_description: ::std::option::Option<::std::string::String>,
8788 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8789 pub localized_memo: ::std::option::Option<::std::string::String>,
8790 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8791 pub longitude: ::std::option::Option<f64>,
8792 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8793 pub memo: ::std::option::Option<::std::string::String>,
8794 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8795 pub merchant_category_code: ::std::option::Option<i64>,
8796 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8797 pub merchant_guid: ::std::option::Option<::std::string::String>,
8798 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8799 pub merchant_location_guid: ::std::option::Option<::std::string::String>,
8800 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8801 pub metadata: ::std::option::Option<::std::string::String>,
8802 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8803 pub posted_at: ::std::option::Option<::std::string::String>,
8804 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8805 pub status: ::std::option::Option<::std::string::String>,
8806 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8807 pub transacted_at: ::std::option::Option<::std::string::String>,
8808 #[serde(
8809 rename = "type",
8810 default,
8811 skip_serializing_if = "::std::option::Option::is_none"
8812 )]
8813 pub type_: ::std::option::Option<::std::string::String>,
8814 }
8815
8816 impl ::std::convert::From<&ManagedTransactionUpdateRequest> for ManagedTransactionUpdateRequest {
8817 fn from(value: &ManagedTransactionUpdateRequest) -> Self {
8818 value.clone()
8819 }
8820 }
8821
8822 impl ::std::default::Default for ManagedTransactionUpdateRequest {
8823 fn default() -> Self {
8824 Self {
8825 amount: Default::default(),
8826 category: Default::default(),
8827 check_number_string: Default::default(),
8828 currency_code: Default::default(),
8829 description: Default::default(),
8830 id: Default::default(),
8831 is_international: Default::default(),
8832 latitude: Default::default(),
8833 localized_description: Default::default(),
8834 localized_memo: Default::default(),
8835 longitude: Default::default(),
8836 memo: Default::default(),
8837 merchant_category_code: Default::default(),
8838 merchant_guid: Default::default(),
8839 merchant_location_guid: Default::default(),
8840 metadata: Default::default(),
8841 posted_at: Default::default(),
8842 status: Default::default(),
8843 transacted_at: Default::default(),
8844 type_: Default::default(),
8845 }
8846 }
8847 }
8848
8849 ///`ManagedTransactionUpdateRequestBody`
8850 ///
8851 /// <details><summary>JSON schema</summary>
8852 ///
8853 /// ```json
8854 ///{
8855 /// "type": "object",
8856 /// "properties": {
8857 /// "transaction": {
8858 /// "$ref": "#/components/schemas/ManagedTransactionUpdateRequest"
8859 /// }
8860 /// }
8861 ///}
8862 /// ```
8863 /// </details>
8864 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
8865 pub struct ManagedTransactionUpdateRequestBody {
8866 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8867 pub transaction: ::std::option::Option<ManagedTransactionUpdateRequest>,
8868 }
8869
8870 impl ::std::convert::From<&ManagedTransactionUpdateRequestBody>
8871 for ManagedTransactionUpdateRequestBody
8872 {
8873 fn from(value: &ManagedTransactionUpdateRequestBody) -> Self {
8874 value.clone()
8875 }
8876 }
8877
8878 impl ::std::default::Default for ManagedTransactionUpdateRequestBody {
8879 fn default() -> Self {
8880 Self {
8881 transaction: Default::default(),
8882 }
8883 }
8884 }
8885
8886 ///`MemberCreateRequest`
8887 ///
8888 /// <details><summary>JSON schema</summary>
8889 ///
8890 /// ```json
8891 ///{
8892 /// "type": "object",
8893 /// "required": [
8894 /// "credentials",
8895 /// "institution_code"
8896 /// ],
8897 /// "properties": {
8898 /// "background_aggregation_is_disabled": {
8899 /// "examples": [
8900 /// false
8901 /// ],
8902 /// "type": "boolean"
8903 /// },
8904 /// "credentials": {
8905 /// "type": "array",
8906 /// "items": {
8907 /// "$ref": "#/components/schemas/CredentialRequest"
8908 /// }
8909 /// },
8910 /// "id": {
8911 /// "examples": [
8912 /// "unique_id"
8913 /// ],
8914 /// "type": "string"
8915 /// },
8916 /// "institution_code": {
8917 /// "examples": [
8918 /// "mxbank"
8919 /// ],
8920 /// "type": "string"
8921 /// },
8922 /// "is_oauth": {
8923 /// "examples": [
8924 /// false
8925 /// ],
8926 /// "type": "boolean"
8927 /// },
8928 /// "metadata": {
8929 /// "examples": [
8930 /// "\\\"credentials_last_refreshed_at\\\": \\\"2015-10-15\\"
8931 /// ],
8932 /// "type": "string"
8933 /// },
8934 /// "skip_aggregation": {
8935 /// "examples": [
8936 /// false
8937 /// ],
8938 /// "type": "boolean"
8939 /// },
8940 /// "use_cases": {
8941 /// "description": "The use case associated with the member. Valid
8942 /// values are `PFM` and/or `MONEY_MOVEMENT`. Only set this if you've met
8943 /// with MX and have opted in to using this field.",
8944 /// "examples": [
8945 /// [
8946 /// "PFM"
8947 /// ]
8948 /// ],
8949 /// "type": "array",
8950 /// "items": {
8951 /// "type": "string",
8952 /// "enum": [
8953 /// "MONEY_MOVEMENT",
8954 /// "PFM"
8955 /// ]
8956 /// }
8957 /// }
8958 /// }
8959 ///}
8960 /// ```
8961 /// </details>
8962 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
8963 pub struct MemberCreateRequest {
8964 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8965 pub background_aggregation_is_disabled: ::std::option::Option<bool>,
8966 pub credentials: ::std::vec::Vec<CredentialRequest>,
8967 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8968 pub id: ::std::option::Option<::std::string::String>,
8969 pub institution_code: ::std::string::String,
8970 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8971 pub is_oauth: ::std::option::Option<bool>,
8972 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8973 pub metadata: ::std::option::Option<::std::string::String>,
8974 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
8975 pub skip_aggregation: ::std::option::Option<bool>,
8976 ///The use case associated with the member. Valid values are `PFM`
8977 /// and/or `MONEY_MOVEMENT`. Only set this if you've met with MX and
8978 /// have opted in to using this field.
8979 #[serde(default, skip_serializing_if = "::std::vec::Vec::is_empty")]
8980 pub use_cases: ::std::vec::Vec<MemberCreateRequestUseCasesItem>,
8981 }
8982
8983 impl ::std::convert::From<&MemberCreateRequest> for MemberCreateRequest {
8984 fn from(value: &MemberCreateRequest) -> Self {
8985 value.clone()
8986 }
8987 }
8988
8989 ///`MemberCreateRequestBody`
8990 ///
8991 /// <details><summary>JSON schema</summary>
8992 ///
8993 /// ```json
8994 ///{
8995 /// "type": "object",
8996 /// "properties": {
8997 /// "client_redirect_url": {
8998 /// "examples": [
8999 /// "https://{yoursite.com}"
9000 /// ],
9001 /// "type": "string"
9002 /// },
9003 /// "enable_app2app": {
9004 /// "description": "This indicates whether OAuth app2app behavior is enabled for institutions that support it. Defaults to `true`. When set to `false`, any `oauth_window_uri` generated will **not** direct the end user to the institution's mobile application. This setting is not persistent. This setting currently only affects Chase institutions.\n",
9005 /// "examples": [
9006 /// false
9007 /// ],
9008 /// "type": "boolean"
9009 /// },
9010 /// "member": {
9011 /// "$ref": "#/components/schemas/MemberCreateRequest"
9012 /// },
9013 /// "referral_source": {
9014 /// "examples": [
9015 /// "APP"
9016 /// ],
9017 /// "type": "string"
9018 /// },
9019 /// "ui_message_webview_url_scheme": {
9020 /// "type": "string"
9021 /// }
9022 /// }
9023 ///}
9024 /// ```
9025 /// </details>
9026 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
9027 pub struct MemberCreateRequestBody {
9028 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
9029 pub client_redirect_url: ::std::option::Option<::std::string::String>,
9030 ///This indicates whether OAuth app2app behavior is enabled for
9031 /// institutions that support it. Defaults to `true`. When set to
9032 /// `false`, any `oauth_window_uri` generated will **not** direct the
9033 /// end user to the institution's mobile application. This setting is
9034 /// not persistent. This setting currently only affects Chase
9035 /// institutions.
9036 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
9037 pub enable_app2app: ::std::option::Option<bool>,
9038 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
9039 pub member: ::std::option::Option<MemberCreateRequest>,
9040 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
9041 pub referral_source: ::std::option::Option<::std::string::String>,
9042 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
9043 pub ui_message_webview_url_scheme: ::std::option::Option<::std::string::String>,
9044 }
9045
9046 impl ::std::convert::From<&MemberCreateRequestBody> for MemberCreateRequestBody {
9047 fn from(value: &MemberCreateRequestBody) -> Self {
9048 value.clone()
9049 }
9050 }
9051
9052 impl ::std::default::Default for MemberCreateRequestBody {
9053 fn default() -> Self {
9054 Self {
9055 client_redirect_url: Default::default(),
9056 enable_app2app: Default::default(),
9057 member: Default::default(),
9058 referral_source: Default::default(),
9059 ui_message_webview_url_scheme: Default::default(),
9060 }
9061 }
9062 }
9063
9064 ///`MemberCreateRequestUseCasesItem`
9065 ///
9066 /// <details><summary>JSON schema</summary>
9067 ///
9068 /// ```json
9069 ///{
9070 /// "type": "string",
9071 /// "enum": [
9072 /// "MONEY_MOVEMENT",
9073 /// "PFM"
9074 /// ]
9075 ///}
9076 /// ```
9077 /// </details>
9078 #[derive(
9079 :: serde :: Deserialize,
9080 :: serde :: Serialize,
9081 Clone,
9082 Copy,
9083 Debug,
9084 Eq,
9085 Hash,
9086 Ord,
9087 PartialEq,
9088 PartialOrd,
9089 )]
9090 pub enum MemberCreateRequestUseCasesItem {
9091 #[serde(rename = "MONEY_MOVEMENT")]
9092 MoneyMovement,
9093 #[serde(rename = "PFM")]
9094 Pfm,
9095 }
9096
9097 impl ::std::convert::From<&Self> for MemberCreateRequestUseCasesItem {
9098 fn from(value: &MemberCreateRequestUseCasesItem) -> Self {
9099 value.clone()
9100 }
9101 }
9102
9103 impl ::std::fmt::Display for MemberCreateRequestUseCasesItem {
9104 fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
9105 match *self {
9106 Self::MoneyMovement => f.write_str("MONEY_MOVEMENT"),
9107 Self::Pfm => f.write_str("PFM"),
9108 }
9109 }
9110 }
9111
9112 impl ::std::str::FromStr for MemberCreateRequestUseCasesItem {
9113 type Err = self::error::ConversionError;
9114 fn from_str(value: &str) -> ::std::result::Result<Self, self::error::ConversionError> {
9115 match value {
9116 "MONEY_MOVEMENT" => Ok(Self::MoneyMovement),
9117 "PFM" => Ok(Self::Pfm),
9118 _ => Err("invalid value".into()),
9119 }
9120 }
9121 }
9122
9123 impl ::std::convert::TryFrom<&str> for MemberCreateRequestUseCasesItem {
9124 type Error = self::error::ConversionError;
9125 fn try_from(value: &str) -> ::std::result::Result<Self, self::error::ConversionError> {
9126 value.parse()
9127 }
9128 }
9129
9130 impl ::std::convert::TryFrom<&::std::string::String> for MemberCreateRequestUseCasesItem {
9131 type Error = self::error::ConversionError;
9132 fn try_from(
9133 value: &::std::string::String,
9134 ) -> ::std::result::Result<Self, self::error::ConversionError> {
9135 value.parse()
9136 }
9137 }
9138
9139 impl ::std::convert::TryFrom<::std::string::String> for MemberCreateRequestUseCasesItem {
9140 type Error = self::error::ConversionError;
9141 fn try_from(
9142 value: ::std::string::String,
9143 ) -> ::std::result::Result<Self, self::error::ConversionError> {
9144 value.parse()
9145 }
9146 }
9147
9148 ///`MemberElements`
9149 ///
9150 /// <details><summary>JSON schema</summary>
9151 ///
9152 /// ```json
9153 ///{
9154 /// "properties": {
9155 /// "account_guid": {
9156 /// "examples": [
9157 /// "ACT-283132a4-1401-486a-909e-1605f1623d11"
9158 /// ],
9159 /// "type": "string"
9160 /// },
9161 /// "member_guid": {
9162 /// "examples": [
9163 /// "MBR-54feffb9-8474-47bd-8442-de003910113a"
9164 /// ],
9165 /// "type": "string"
9166 /// },
9167 /// "user_guid": {
9168 /// "examples": [
9169 /// "USR-101ad774-288b-44ed-ad16-da87d522ea20"
9170 /// ],
9171 /// "type": "string"
9172 /// }
9173 /// }
9174 ///}
9175 /// ```
9176 /// </details>
9177 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
9178 pub struct MemberElements {
9179 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
9180 pub account_guid: ::std::option::Option<::std::string::String>,
9181 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
9182 pub member_guid: ::std::option::Option<::std::string::String>,
9183 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
9184 pub user_guid: ::std::option::Option<::std::string::String>,
9185 }
9186
9187 impl ::std::convert::From<&MemberElements> for MemberElements {
9188 fn from(value: &MemberElements) -> Self {
9189 value.clone()
9190 }
9191 }
9192
9193 impl ::std::default::Default for MemberElements {
9194 fn default() -> Self {
9195 Self {
9196 account_guid: Default::default(),
9197 member_guid: Default::default(),
9198 user_guid: Default::default(),
9199 }
9200 }
9201 }
9202
9203 ///`MemberResponse`
9204 ///
9205 /// <details><summary>JSON schema</summary>
9206 ///
9207 /// ```json
9208 ///{
9209 /// "type": "object",
9210 /// "properties": {
9211 /// "aggregated_at": {
9212 /// "examples": [
9213 /// "2016-10-13T18:07:57.000Z"
9214 /// ],
9215 /// "type": [
9216 /// "string",
9217 /// "null"
9218 /// ]
9219 /// },
9220 /// "background_aggregation_is_disabled": {
9221 /// "examples": [
9222 /// false
9223 /// ],
9224 /// "type": "boolean"
9225 /// },
9226 /// "connection_status": {
9227 /// "examples": [
9228 /// "CONNECTED"
9229 /// ],
9230 /// "type": [
9231 /// "string",
9232 /// "null"
9233 /// ]
9234 /// },
9235 /// "connection_status_message": {
9236 /// "examples": [
9237 /// "Connected to MX Bank"
9238 /// ],
9239 /// "type": [
9240 /// "string",
9241 /// "null"
9242 /// ]
9243 /// },
9244 /// "guid": {
9245 /// "examples": [
9246 /// "MBR-7c6f361b-e582-15b6-60c0-358f12466b4b"
9247 /// ],
9248 /// "type": [
9249 /// "string",
9250 /// "null"
9251 /// ]
9252 /// },
9253 /// "id": {
9254 /// "examples": [
9255 /// "unique_id"
9256 /// ],
9257 /// "type": [
9258 /// "string",
9259 /// "null"
9260 /// ]
9261 /// },
9262 /// "institution_code": {
9263 /// "examples": [
9264 /// "mxbank"
9265 /// ],
9266 /// "type": [
9267 /// "string",
9268 /// "null"
9269 /// ]
9270 /// },
9271 /// "institution_guid": {
9272 /// "examples": [
9273 /// "INST-12345678-90ab-cdef-1234-567890abcdef"
9274 /// ],
9275 /// "type": "string"
9276 /// },
9277 /// "is_being_aggregated": {
9278 /// "examples": [
9279 /// false
9280 /// ],
9281 /// "type": [
9282 /// "boolean",
9283 /// "null"
9284 /// ]
9285 /// },
9286 /// "is_managed_by_user": {
9287 /// "examples": [
9288 /// false
9289 /// ],
9290 /// "type": [
9291 /// "boolean",
9292 /// "null"
9293 /// ]
9294 /// },
9295 /// "is_manual": {
9296 /// "examples": [
9297 /// false
9298 /// ],
9299 /// "type": [
9300 /// "boolean",
9301 /// "null"
9302 /// ]
9303 /// },
9304 /// "is_oauth": {
9305 /// "examples": [
9306 /// false
9307 /// ],
9308 /// "type": [
9309 /// "boolean",
9310 /// "null"
9311 /// ]
9312 /// },
9313 /// "metadata": {
9314 /// "examples": [
9315 /// "\\\"credentials_last_refreshed_at\\\": \\\"2015-10-15\\"
9316 /// ],
9317 /// "type": [
9318 /// "string",
9319 /// "null"
9320 /// ]
9321 /// },
9322 /// "most_recent_job_detail_code": {
9323 /// "type": [
9324 /// "integer",
9325 /// "null"
9326 /// ]
9327 /// },
9328 /// "most_recent_job_detail_text": {
9329 /// "type": [
9330 /// "boolean",
9331 /// "null"
9332 /// ]
9333 /// },
9334 /// "most_recent_job_guid": {
9335 /// "examples": [
9336 /// "JOB-12345678-90ab-cdef-1234-567890abcdef"
9337 /// ],
9338 /// "type": [
9339 /// "boolean",
9340 /// "null"
9341 /// ]
9342 /// },
9343 /// "name": {
9344 /// "examples": [
9345 /// "MX Bank"
9346 /// ],
9347 /// "type": [
9348 /// "string",
9349 /// "null"
9350 /// ]
9351 /// },
9352 /// "needs_updated_credentials": {
9353 /// "examples": [
9354 /// false
9355 /// ],
9356 /// "type": [
9357 /// "boolean",
9358 /// "null"
9359 /// ]
9360 /// },
9361 /// "oauth_window_uri": {
9362 /// "examples": [
9363 /// "https://mxbank.mx.com/oauth/authorize?client_id=b8OikQ4Ep3NuSUrQ13DdvFuwpNx-qqoAsJDVAQCyLkQ&redirect_uri=https%3A%2F%2Fint-app.moneydesktop.com%2Foauth%2Fredirect_from&response_type=code&scope=openid&state=d745bd4ee6f0f9c184757f574bcc2df2"
9364 /// ],
9365 /// "type": [
9366 /// "string",
9367 /// "null"
9368 /// ]
9369 /// },
9370 /// "successfully_aggregated_at": {
9371 /// "examples": [
9372 /// "2016-10-13T17:57:38.000Z"
9373 /// ],
9374 /// "type": [
9375 /// "string",
9376 /// "null"
9377 /// ]
9378 /// },
9379 /// "use_cases": {
9380 /// "description": "The use case associated with the member. Valid
9381 /// values are `PFM` and/or `MONEY_MOVEMENT`. Only set this if you've met
9382 /// with MX and have opted in to using this field.",
9383 /// "examples": [
9384 /// [
9385 /// "PFM"
9386 /// ]
9387 /// ],
9388 /// "type": "array",
9389 /// "items": {
9390 /// "type": "string",
9391 /// "enum": [
9392 /// "MONEY_MOVEMENT",
9393 /// "PFM"
9394 /// ]
9395 /// }
9396 /// },
9397 /// "user_guid": {
9398 /// "examples": [
9399 /// "USR-fa7537f3-48aa-a683-a02a-b18940482f54"
9400 /// ],
9401 /// "type": [
9402 /// "string",
9403 /// "null"
9404 /// ]
9405 /// },
9406 /// "user_id": {
9407 /// "examples": [
9408 /// "user123"
9409 /// ],
9410 /// "type": [
9411 /// "string",
9412 /// "null"
9413 /// ]
9414 /// }
9415 /// }
9416 ///}
9417 /// ```
9418 /// </details>
9419 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
9420 pub struct MemberResponse {
9421 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
9422 pub aggregated_at: ::std::option::Option<::std::string::String>,
9423 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
9424 pub background_aggregation_is_disabled: ::std::option::Option<bool>,
9425 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
9426 pub connection_status: ::std::option::Option<::std::string::String>,
9427 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
9428 pub connection_status_message: ::std::option::Option<::std::string::String>,
9429 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
9430 pub guid: ::std::option::Option<::std::string::String>,
9431 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
9432 pub id: ::std::option::Option<::std::string::String>,
9433 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
9434 pub institution_code: ::std::option::Option<::std::string::String>,
9435 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
9436 pub institution_guid: ::std::option::Option<::std::string::String>,
9437 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
9438 pub is_being_aggregated: ::std::option::Option<bool>,
9439 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
9440 pub is_managed_by_user: ::std::option::Option<bool>,
9441 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
9442 pub is_manual: ::std::option::Option<bool>,
9443 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
9444 pub is_oauth: ::std::option::Option<bool>,
9445 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
9446 pub metadata: ::std::option::Option<::std::string::String>,
9447 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
9448 pub most_recent_job_detail_code: ::std::option::Option<i64>,
9449 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
9450 pub most_recent_job_detail_text: ::std::option::Option<bool>,
9451 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
9452 pub most_recent_job_guid: ::std::option::Option<bool>,
9453 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
9454 pub name: ::std::option::Option<::std::string::String>,
9455 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
9456 pub needs_updated_credentials: ::std::option::Option<bool>,
9457 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
9458 pub oauth_window_uri: ::std::option::Option<::std::string::String>,
9459 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
9460 pub successfully_aggregated_at: ::std::option::Option<::std::string::String>,
9461 ///The use case associated with the member. Valid values are `PFM`
9462 /// and/or `MONEY_MOVEMENT`. Only set this if you've met with MX and
9463 /// have opted in to using this field.
9464 #[serde(default, skip_serializing_if = "::std::vec::Vec::is_empty")]
9465 pub use_cases: ::std::vec::Vec<MemberResponseUseCasesItem>,
9466 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
9467 pub user_guid: ::std::option::Option<::std::string::String>,
9468 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
9469 pub user_id: ::std::option::Option<::std::string::String>,
9470 }
9471
9472 impl ::std::convert::From<&MemberResponse> for MemberResponse {
9473 fn from(value: &MemberResponse) -> Self {
9474 value.clone()
9475 }
9476 }
9477
9478 impl ::std::default::Default for MemberResponse {
9479 fn default() -> Self {
9480 Self {
9481 aggregated_at: Default::default(),
9482 background_aggregation_is_disabled: Default::default(),
9483 connection_status: Default::default(),
9484 connection_status_message: Default::default(),
9485 guid: Default::default(),
9486 id: Default::default(),
9487 institution_code: Default::default(),
9488 institution_guid: Default::default(),
9489 is_being_aggregated: Default::default(),
9490 is_managed_by_user: Default::default(),
9491 is_manual: Default::default(),
9492 is_oauth: Default::default(),
9493 metadata: Default::default(),
9494 most_recent_job_detail_code: Default::default(),
9495 most_recent_job_detail_text: Default::default(),
9496 most_recent_job_guid: Default::default(),
9497 name: Default::default(),
9498 needs_updated_credentials: Default::default(),
9499 oauth_window_uri: Default::default(),
9500 successfully_aggregated_at: Default::default(),
9501 use_cases: Default::default(),
9502 user_guid: Default::default(),
9503 user_id: Default::default(),
9504 }
9505 }
9506 }
9507
9508 ///`MemberResponseBody`
9509 ///
9510 /// <details><summary>JSON schema</summary>
9511 ///
9512 /// ```json
9513 ///{
9514 /// "type": "object",
9515 /// "properties": {
9516 /// "member": {
9517 /// "$ref": "#/components/schemas/MemberResponse"
9518 /// }
9519 /// }
9520 ///}
9521 /// ```
9522 /// </details>
9523 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
9524 pub struct MemberResponseBody {
9525 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
9526 pub member: ::std::option::Option<MemberResponse>,
9527 }
9528
9529 impl ::std::convert::From<&MemberResponseBody> for MemberResponseBody {
9530 fn from(value: &MemberResponseBody) -> Self {
9531 value.clone()
9532 }
9533 }
9534
9535 impl ::std::default::Default for MemberResponseBody {
9536 fn default() -> Self {
9537 Self {
9538 member: Default::default(),
9539 }
9540 }
9541 }
9542
9543 ///`MemberResponseUseCasesItem`
9544 ///
9545 /// <details><summary>JSON schema</summary>
9546 ///
9547 /// ```json
9548 ///{
9549 /// "type": "string",
9550 /// "enum": [
9551 /// "MONEY_MOVEMENT",
9552 /// "PFM"
9553 /// ]
9554 ///}
9555 /// ```
9556 /// </details>
9557 #[derive(
9558 :: serde :: Deserialize,
9559 :: serde :: Serialize,
9560 Clone,
9561 Copy,
9562 Debug,
9563 Eq,
9564 Hash,
9565 Ord,
9566 PartialEq,
9567 PartialOrd,
9568 )]
9569 pub enum MemberResponseUseCasesItem {
9570 #[serde(rename = "MONEY_MOVEMENT")]
9571 MoneyMovement,
9572 #[serde(rename = "PFM")]
9573 Pfm,
9574 }
9575
9576 impl ::std::convert::From<&Self> for MemberResponseUseCasesItem {
9577 fn from(value: &MemberResponseUseCasesItem) -> Self {
9578 value.clone()
9579 }
9580 }
9581
9582 impl ::std::fmt::Display for MemberResponseUseCasesItem {
9583 fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
9584 match *self {
9585 Self::MoneyMovement => f.write_str("MONEY_MOVEMENT"),
9586 Self::Pfm => f.write_str("PFM"),
9587 }
9588 }
9589 }
9590
9591 impl ::std::str::FromStr for MemberResponseUseCasesItem {
9592 type Err = self::error::ConversionError;
9593 fn from_str(value: &str) -> ::std::result::Result<Self, self::error::ConversionError> {
9594 match value {
9595 "MONEY_MOVEMENT" => Ok(Self::MoneyMovement),
9596 "PFM" => Ok(Self::Pfm),
9597 _ => Err("invalid value".into()),
9598 }
9599 }
9600 }
9601
9602 impl ::std::convert::TryFrom<&str> for MemberResponseUseCasesItem {
9603 type Error = self::error::ConversionError;
9604 fn try_from(value: &str) -> ::std::result::Result<Self, self::error::ConversionError> {
9605 value.parse()
9606 }
9607 }
9608
9609 impl ::std::convert::TryFrom<&::std::string::String> for MemberResponseUseCasesItem {
9610 type Error = self::error::ConversionError;
9611 fn try_from(
9612 value: &::std::string::String,
9613 ) -> ::std::result::Result<Self, self::error::ConversionError> {
9614 value.parse()
9615 }
9616 }
9617
9618 impl ::std::convert::TryFrom<::std::string::String> for MemberResponseUseCasesItem {
9619 type Error = self::error::ConversionError;
9620 fn try_from(
9621 value: ::std::string::String,
9622 ) -> ::std::result::Result<Self, self::error::ConversionError> {
9623 value.parse()
9624 }
9625 }
9626
9627 ///`MemberResumeRequest`
9628 ///
9629 /// <details><summary>JSON schema</summary>
9630 ///
9631 /// ```json
9632 ///{
9633 /// "type": "object",
9634 /// "properties": {
9635 /// "challenges": {
9636 /// "type": "array",
9637 /// "items": {
9638 /// "$ref": "#/components/schemas/CredentialRequest"
9639 /// }
9640 /// }
9641 /// }
9642 ///}
9643 /// ```
9644 /// </details>
9645 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
9646 pub struct MemberResumeRequest {
9647 #[serde(default, skip_serializing_if = "::std::vec::Vec::is_empty")]
9648 pub challenges: ::std::vec::Vec<CredentialRequest>,
9649 }
9650
9651 impl ::std::convert::From<&MemberResumeRequest> for MemberResumeRequest {
9652 fn from(value: &MemberResumeRequest) -> Self {
9653 value.clone()
9654 }
9655 }
9656
9657 impl ::std::default::Default for MemberResumeRequest {
9658 fn default() -> Self {
9659 Self {
9660 challenges: Default::default(),
9661 }
9662 }
9663 }
9664
9665 ///`MemberResumeRequestBody`
9666 ///
9667 /// <details><summary>JSON schema</summary>
9668 ///
9669 /// ```json
9670 ///{
9671 /// "type": "object",
9672 /// "properties": {
9673 /// "member": {
9674 /// "$ref": "#/components/schemas/MemberResumeRequest"
9675 /// }
9676 /// }
9677 ///}
9678 /// ```
9679 /// </details>
9680 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
9681 pub struct MemberResumeRequestBody {
9682 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
9683 pub member: ::std::option::Option<MemberResumeRequest>,
9684 }
9685
9686 impl ::std::convert::From<&MemberResumeRequestBody> for MemberResumeRequestBody {
9687 fn from(value: &MemberResumeRequestBody) -> Self {
9688 value.clone()
9689 }
9690 }
9691
9692 impl ::std::default::Default for MemberResumeRequestBody {
9693 fn default() -> Self {
9694 Self {
9695 member: Default::default(),
9696 }
9697 }
9698 }
9699
9700 ///`MemberStatusResponse`
9701 ///
9702 /// <details><summary>JSON schema</summary>
9703 ///
9704 /// ```json
9705 ///{
9706 /// "type": "object",
9707 /// "properties": {
9708 /// "aggregated_at": {
9709 /// "examples": [
9710 /// "2016-10-13T18:07:57.000Z"
9711 /// ],
9712 /// "type": [
9713 /// "string",
9714 /// "null"
9715 /// ]
9716 /// },
9717 /// "challenges": {
9718 /// "type": "array",
9719 /// "items": {
9720 /// "$ref": "#/components/schemas/ChallengeResponse"
9721 /// }
9722 /// },
9723 /// "connection_status": {
9724 /// "examples": [
9725 /// "CONNECTED"
9726 /// ],
9727 /// "type": [
9728 /// "string",
9729 /// "null"
9730 /// ]
9731 /// },
9732 /// "guid": {
9733 /// "examples": [
9734 /// "MBR-7c6f361b-e582-15b6-60c0-358f12466b4b"
9735 /// ],
9736 /// "type": [
9737 /// "string",
9738 /// "null"
9739 /// ]
9740 /// },
9741 /// "has_processed_account_numbers": {
9742 /// "examples": [
9743 /// true
9744 /// ],
9745 /// "type": [
9746 /// "boolean",
9747 /// "null"
9748 /// ]
9749 /// },
9750 /// "has_processed_accounts": {
9751 /// "examples": [
9752 /// true
9753 /// ],
9754 /// "type": [
9755 /// "boolean",
9756 /// "null"
9757 /// ]
9758 /// },
9759 /// "has_processed_transactions": {
9760 /// "examples": [
9761 /// false
9762 /// ],
9763 /// "type": [
9764 /// "boolean",
9765 /// "null"
9766 /// ]
9767 /// },
9768 /// "is_authenticated": {
9769 /// "examples": [
9770 /// false
9771 /// ],
9772 /// "type": [
9773 /// "boolean",
9774 /// "null"
9775 /// ]
9776 /// },
9777 /// "is_being_aggregated": {
9778 /// "examples": [
9779 /// false
9780 /// ],
9781 /// "type": [
9782 /// "boolean",
9783 /// "null"
9784 /// ]
9785 /// },
9786 /// "successfully_aggregated_at": {
9787 /// "examples": [
9788 /// "2016-10-13T17:57:38.000Z"
9789 /// ],
9790 /// "type": [
9791 /// "string",
9792 /// "null"
9793 /// ]
9794 /// }
9795 /// }
9796 ///}
9797 /// ```
9798 /// </details>
9799 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
9800 pub struct MemberStatusResponse {
9801 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
9802 pub aggregated_at: ::std::option::Option<::std::string::String>,
9803 #[serde(default, skip_serializing_if = "::std::vec::Vec::is_empty")]
9804 pub challenges: ::std::vec::Vec<ChallengeResponse>,
9805 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
9806 pub connection_status: ::std::option::Option<::std::string::String>,
9807 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
9808 pub guid: ::std::option::Option<::std::string::String>,
9809 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
9810 pub has_processed_account_numbers: ::std::option::Option<bool>,
9811 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
9812 pub has_processed_accounts: ::std::option::Option<bool>,
9813 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
9814 pub has_processed_transactions: ::std::option::Option<bool>,
9815 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
9816 pub is_authenticated: ::std::option::Option<bool>,
9817 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
9818 pub is_being_aggregated: ::std::option::Option<bool>,
9819 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
9820 pub successfully_aggregated_at: ::std::option::Option<::std::string::String>,
9821 }
9822
9823 impl ::std::convert::From<&MemberStatusResponse> for MemberStatusResponse {
9824 fn from(value: &MemberStatusResponse) -> Self {
9825 value.clone()
9826 }
9827 }
9828
9829 impl ::std::default::Default for MemberStatusResponse {
9830 fn default() -> Self {
9831 Self {
9832 aggregated_at: Default::default(),
9833 challenges: Default::default(),
9834 connection_status: Default::default(),
9835 guid: Default::default(),
9836 has_processed_account_numbers: Default::default(),
9837 has_processed_accounts: Default::default(),
9838 has_processed_transactions: Default::default(),
9839 is_authenticated: Default::default(),
9840 is_being_aggregated: Default::default(),
9841 successfully_aggregated_at: Default::default(),
9842 }
9843 }
9844 }
9845
9846 ///`MemberStatusResponseBody`
9847 ///
9848 /// <details><summary>JSON schema</summary>
9849 ///
9850 /// ```json
9851 ///{
9852 /// "type": "object",
9853 /// "properties": {
9854 /// "member": {
9855 /// "$ref": "#/components/schemas/MemberStatusResponse"
9856 /// }
9857 /// }
9858 ///}
9859 /// ```
9860 /// </details>
9861 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
9862 pub struct MemberStatusResponseBody {
9863 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
9864 pub member: ::std::option::Option<MemberStatusResponse>,
9865 }
9866
9867 impl ::std::convert::From<&MemberStatusResponseBody> for MemberStatusResponseBody {
9868 fn from(value: &MemberStatusResponseBody) -> Self {
9869 value.clone()
9870 }
9871 }
9872
9873 impl ::std::default::Default for MemberStatusResponseBody {
9874 fn default() -> Self {
9875 Self {
9876 member: Default::default(),
9877 }
9878 }
9879 }
9880
9881 ///`MemberUpdateRequest`
9882 ///
9883 /// <details><summary>JSON schema</summary>
9884 ///
9885 /// ```json
9886 ///{
9887 /// "type": "object",
9888 /// "properties": {
9889 /// "background_aggregation_is_disabled": {
9890 /// "examples": [
9891 /// false
9892 /// ],
9893 /// "type": "boolean"
9894 /// },
9895 /// "credentials": {
9896 /// "type": "array",
9897 /// "items": {
9898 /// "$ref": "#/components/schemas/CredentialRequest"
9899 /// }
9900 /// },
9901 /// "id": {
9902 /// "examples": [
9903 /// "unique_id"
9904 /// ],
9905 /// "type": "string"
9906 /// },
9907 /// "metadata": {
9908 /// "examples": [
9909 /// "\\\"credentials_last_refreshed_at\\\": \\\"2015-10-15\\"
9910 /// ],
9911 /// "type": "string"
9912 /// },
9913 /// "skip_aggregation": {
9914 /// "examples": [
9915 /// false
9916 /// ],
9917 /// "type": "boolean"
9918 /// },
9919 /// "use_cases": {
9920 /// "description": "The use case associated with the member. Valid
9921 /// values are `PFM` and/or `MONEY_MOVEMENT`. Only set this if you've met
9922 /// with MX and have opted in to using this field.",
9923 /// "examples": [
9924 /// [
9925 /// "PFM"
9926 /// ]
9927 /// ],
9928 /// "type": "array",
9929 /// "items": {
9930 /// "type": "string",
9931 /// "enum": [
9932 /// "MONEY_MOVEMENT",
9933 /// "PFM"
9934 /// ]
9935 /// }
9936 /// }
9937 /// }
9938 ///}
9939 /// ```
9940 /// </details>
9941 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
9942 pub struct MemberUpdateRequest {
9943 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
9944 pub background_aggregation_is_disabled: ::std::option::Option<bool>,
9945 #[serde(default, skip_serializing_if = "::std::vec::Vec::is_empty")]
9946 pub credentials: ::std::vec::Vec<CredentialRequest>,
9947 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
9948 pub id: ::std::option::Option<::std::string::String>,
9949 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
9950 pub metadata: ::std::option::Option<::std::string::String>,
9951 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
9952 pub skip_aggregation: ::std::option::Option<bool>,
9953 ///The use case associated with the member. Valid values are `PFM`
9954 /// and/or `MONEY_MOVEMENT`. Only set this if you've met with MX and
9955 /// have opted in to using this field.
9956 #[serde(default, skip_serializing_if = "::std::vec::Vec::is_empty")]
9957 pub use_cases: ::std::vec::Vec<MemberUpdateRequestUseCasesItem>,
9958 }
9959
9960 impl ::std::convert::From<&MemberUpdateRequest> for MemberUpdateRequest {
9961 fn from(value: &MemberUpdateRequest) -> Self {
9962 value.clone()
9963 }
9964 }
9965
9966 impl ::std::default::Default for MemberUpdateRequest {
9967 fn default() -> Self {
9968 Self {
9969 background_aggregation_is_disabled: Default::default(),
9970 credentials: Default::default(),
9971 id: Default::default(),
9972 metadata: Default::default(),
9973 skip_aggregation: Default::default(),
9974 use_cases: Default::default(),
9975 }
9976 }
9977 }
9978
9979 ///`MemberUpdateRequestBody`
9980 ///
9981 /// <details><summary>JSON schema</summary>
9982 ///
9983 /// ```json
9984 ///{
9985 /// "type": "object",
9986 /// "properties": {
9987 /// "member": {
9988 /// "$ref": "#/components/schemas/MemberUpdateRequest"
9989 /// }
9990 /// }
9991 ///}
9992 /// ```
9993 /// </details>
9994 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
9995 pub struct MemberUpdateRequestBody {
9996 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
9997 pub member: ::std::option::Option<MemberUpdateRequest>,
9998 }
9999
10000 impl ::std::convert::From<&MemberUpdateRequestBody> for MemberUpdateRequestBody {
10001 fn from(value: &MemberUpdateRequestBody) -> Self {
10002 value.clone()
10003 }
10004 }
10005
10006 impl ::std::default::Default for MemberUpdateRequestBody {
10007 fn default() -> Self {
10008 Self {
10009 member: Default::default(),
10010 }
10011 }
10012 }
10013
10014 ///`MemberUpdateRequestUseCasesItem`
10015 ///
10016 /// <details><summary>JSON schema</summary>
10017 ///
10018 /// ```json
10019 ///{
10020 /// "type": "string",
10021 /// "enum": [
10022 /// "MONEY_MOVEMENT",
10023 /// "PFM"
10024 /// ]
10025 ///}
10026 /// ```
10027 /// </details>
10028 #[derive(
10029 :: serde :: Deserialize,
10030 :: serde :: Serialize,
10031 Clone,
10032 Copy,
10033 Debug,
10034 Eq,
10035 Hash,
10036 Ord,
10037 PartialEq,
10038 PartialOrd,
10039 )]
10040 pub enum MemberUpdateRequestUseCasesItem {
10041 #[serde(rename = "MONEY_MOVEMENT")]
10042 MoneyMovement,
10043 #[serde(rename = "PFM")]
10044 Pfm,
10045 }
10046
10047 impl ::std::convert::From<&Self> for MemberUpdateRequestUseCasesItem {
10048 fn from(value: &MemberUpdateRequestUseCasesItem) -> Self {
10049 value.clone()
10050 }
10051 }
10052
10053 impl ::std::fmt::Display for MemberUpdateRequestUseCasesItem {
10054 fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
10055 match *self {
10056 Self::MoneyMovement => f.write_str("MONEY_MOVEMENT"),
10057 Self::Pfm => f.write_str("PFM"),
10058 }
10059 }
10060 }
10061
10062 impl ::std::str::FromStr for MemberUpdateRequestUseCasesItem {
10063 type Err = self::error::ConversionError;
10064 fn from_str(value: &str) -> ::std::result::Result<Self, self::error::ConversionError> {
10065 match value {
10066 "MONEY_MOVEMENT" => Ok(Self::MoneyMovement),
10067 "PFM" => Ok(Self::Pfm),
10068 _ => Err("invalid value".into()),
10069 }
10070 }
10071 }
10072
10073 impl ::std::convert::TryFrom<&str> for MemberUpdateRequestUseCasesItem {
10074 type Error = self::error::ConversionError;
10075 fn try_from(value: &str) -> ::std::result::Result<Self, self::error::ConversionError> {
10076 value.parse()
10077 }
10078 }
10079
10080 impl ::std::convert::TryFrom<&::std::string::String> for MemberUpdateRequestUseCasesItem {
10081 type Error = self::error::ConversionError;
10082 fn try_from(
10083 value: &::std::string::String,
10084 ) -> ::std::result::Result<Self, self::error::ConversionError> {
10085 value.parse()
10086 }
10087 }
10088
10089 impl ::std::convert::TryFrom<::std::string::String> for MemberUpdateRequestUseCasesItem {
10090 type Error = self::error::ConversionError;
10091 fn try_from(
10092 value: ::std::string::String,
10093 ) -> ::std::result::Result<Self, self::error::ConversionError> {
10094 value.parse()
10095 }
10096 }
10097
10098 ///`MembersResponseBody`
10099 ///
10100 /// <details><summary>JSON schema</summary>
10101 ///
10102 /// ```json
10103 ///{
10104 /// "type": "object",
10105 /// "properties": {
10106 /// "members": {
10107 /// "type": "array",
10108 /// "items": {
10109 /// "$ref": "#/components/schemas/MemberResponse"
10110 /// }
10111 /// },
10112 /// "pagination": {
10113 /// "$ref": "#/components/schemas/PaginationResponse"
10114 /// }
10115 /// }
10116 ///}
10117 /// ```
10118 /// </details>
10119 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
10120 pub struct MembersResponseBody {
10121 #[serde(default, skip_serializing_if = "::std::vec::Vec::is_empty")]
10122 pub members: ::std::vec::Vec<MemberResponse>,
10123 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
10124 pub pagination: ::std::option::Option<PaginationResponse>,
10125 }
10126
10127 impl ::std::convert::From<&MembersResponseBody> for MembersResponseBody {
10128 fn from(value: &MembersResponseBody) -> Self {
10129 value.clone()
10130 }
10131 }
10132
10133 impl ::std::default::Default for MembersResponseBody {
10134 fn default() -> Self {
10135 Self {
10136 members: Default::default(),
10137 pagination: Default::default(),
10138 }
10139 }
10140 }
10141
10142 ///`MerchantLocationResponse`
10143 ///
10144 /// <details><summary>JSON schema</summary>
10145 ///
10146 /// ```json
10147 ///{
10148 /// "type": "object",
10149 /// "properties": {
10150 /// "city": {
10151 /// "examples": [
10152 /// "Greenwood Village"
10153 /// ],
10154 /// "type": [
10155 /// "string",
10156 /// "null"
10157 /// ]
10158 /// },
10159 /// "country": {
10160 /// "examples": [
10161 /// "US"
10162 /// ],
10163 /// "type": [
10164 /// "string",
10165 /// "null"
10166 /// ]
10167 /// },
10168 /// "created_at": {
10169 /// "examples": [
10170 /// "2020-04-13 21:05:09.000000000 Z"
10171 /// ],
10172 /// "type": [
10173 /// "string",
10174 /// "null"
10175 /// ]
10176 /// },
10177 /// "guid": {
10178 /// "examples": [
10179 /// "MCL-00024e59-18b5-4d79-b879-2a7896726fea"
10180 /// ],
10181 /// "type": [
10182 /// "string",
10183 /// "null"
10184 /// ]
10185 /// },
10186 /// "latitude": {
10187 /// "examples": [
10188 /// 39.5963005
10189 /// ],
10190 /// "type": [
10191 /// "number",
10192 /// "null"
10193 /// ]
10194 /// },
10195 /// "longitude": {
10196 /// "examples": [
10197 /// -104.89158799999998
10198 /// ],
10199 /// "type": [
10200 /// "number",
10201 /// "null"
10202 /// ]
10203 /// },
10204 /// "merchant_guid": {
10205 /// "examples": [
10206 /// "MCH-09466f0a-fb58-9d1a-bae2-2af0afbea621"
10207 /// ],
10208 /// "type": [
10209 /// "string",
10210 /// "null"
10211 /// ]
10212 /// },
10213 /// "phone_number": {
10214 /// "examples": [
10215 /// "(303) 689-0728"
10216 /// ],
10217 /// "type": [
10218 /// "string",
10219 /// "null"
10220 /// ]
10221 /// },
10222 /// "postal_code": {
10223 /// "examples": [
10224 /// "801121436"
10225 /// ],
10226 /// "type": [
10227 /// "string",
10228 /// "null"
10229 /// ]
10230 /// },
10231 /// "state": {
10232 /// "examples": [
10233 /// "CO"
10234 /// ],
10235 /// "type": [
10236 /// "string",
10237 /// "null"
10238 /// ]
10239 /// },
10240 /// "street_address": {
10241 /// "examples": [
10242 /// "8547 E Arapahoe Rd, Ste 1"
10243 /// ],
10244 /// "type": [
10245 /// "string",
10246 /// "null"
10247 /// ]
10248 /// },
10249 /// "updated_at": {
10250 /// "examples": [
10251 /// "2020-04-13 21:05:09.000000000 Z"
10252 /// ],
10253 /// "type": [
10254 /// "string",
10255 /// "null"
10256 /// ]
10257 /// }
10258 /// }
10259 ///}
10260 /// ```
10261 /// </details>
10262 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
10263 pub struct MerchantLocationResponse {
10264 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
10265 pub city: ::std::option::Option<::std::string::String>,
10266 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
10267 pub country: ::std::option::Option<::std::string::String>,
10268 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
10269 pub created_at: ::std::option::Option<::std::string::String>,
10270 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
10271 pub guid: ::std::option::Option<::std::string::String>,
10272 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
10273 pub latitude: ::std::option::Option<f64>,
10274 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
10275 pub longitude: ::std::option::Option<f64>,
10276 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
10277 pub merchant_guid: ::std::option::Option<::std::string::String>,
10278 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
10279 pub phone_number: ::std::option::Option<::std::string::String>,
10280 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
10281 pub postal_code: ::std::option::Option<::std::string::String>,
10282 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
10283 pub state: ::std::option::Option<::std::string::String>,
10284 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
10285 pub street_address: ::std::option::Option<::std::string::String>,
10286 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
10287 pub updated_at: ::std::option::Option<::std::string::String>,
10288 }
10289
10290 impl ::std::convert::From<&MerchantLocationResponse> for MerchantLocationResponse {
10291 fn from(value: &MerchantLocationResponse) -> Self {
10292 value.clone()
10293 }
10294 }
10295
10296 impl ::std::default::Default for MerchantLocationResponse {
10297 fn default() -> Self {
10298 Self {
10299 city: Default::default(),
10300 country: Default::default(),
10301 created_at: Default::default(),
10302 guid: Default::default(),
10303 latitude: Default::default(),
10304 longitude: Default::default(),
10305 merchant_guid: Default::default(),
10306 phone_number: Default::default(),
10307 postal_code: Default::default(),
10308 state: Default::default(),
10309 street_address: Default::default(),
10310 updated_at: Default::default(),
10311 }
10312 }
10313 }
10314
10315 ///`MerchantLocationResponseBody`
10316 ///
10317 /// <details><summary>JSON schema</summary>
10318 ///
10319 /// ```json
10320 ///{
10321 /// "type": "object",
10322 /// "properties": {
10323 /// "merchant_location": {
10324 /// "$ref": "#/components/schemas/MerchantLocationResponse"
10325 /// }
10326 /// }
10327 ///}
10328 /// ```
10329 /// </details>
10330 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
10331 pub struct MerchantLocationResponseBody {
10332 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
10333 pub merchant_location: ::std::option::Option<MerchantLocationResponse>,
10334 }
10335
10336 impl ::std::convert::From<&MerchantLocationResponseBody> for MerchantLocationResponseBody {
10337 fn from(value: &MerchantLocationResponseBody) -> Self {
10338 value.clone()
10339 }
10340 }
10341
10342 impl ::std::default::Default for MerchantLocationResponseBody {
10343 fn default() -> Self {
10344 Self {
10345 merchant_location: Default::default(),
10346 }
10347 }
10348 }
10349
10350 ///`MerchantResponse`
10351 ///
10352 /// <details><summary>JSON schema</summary>
10353 ///
10354 /// ```json
10355 ///{
10356 /// "type": "object",
10357 /// "properties": {
10358 /// "created_at": {
10359 /// "examples": [
10360 /// "2017-04-20T19:30:12.000Z"
10361 /// ],
10362 /// "type": [
10363 /// "string",
10364 /// "null"
10365 /// ]
10366 /// },
10367 /// "guid": {
10368 /// "examples": [
10369 /// "MCH-7ed79542-884d-2b1b-dd74-501c5cc9d25b"
10370 /// ],
10371 /// "type": [
10372 /// "string",
10373 /// "null"
10374 /// ]
10375 /// },
10376 /// "logo_url": {
10377 /// "examples": [
10378 /// "https://s3.amazonaws.com/MD_Assets/merchant_logos/comcast.png"
10379 /// ],
10380 /// "type": [
10381 /// "string",
10382 /// "null"
10383 /// ]
10384 /// },
10385 /// "name": {
10386 /// "examples": [
10387 /// "Comcast"
10388 /// ],
10389 /// "type": [
10390 /// "string",
10391 /// "null"
10392 /// ]
10393 /// },
10394 /// "updated_at": {
10395 /// "examples": [
10396 /// "2018-09-28T21:13:53.000Z"
10397 /// ],
10398 /// "type": [
10399 /// "string",
10400 /// "null"
10401 /// ]
10402 /// },
10403 /// "website_url": {
10404 /// "examples": [
10405 /// "https://www.xfinity.com"
10406 /// ],
10407 /// "type": [
10408 /// "string",
10409 /// "null"
10410 /// ]
10411 /// }
10412 /// }
10413 ///}
10414 /// ```
10415 /// </details>
10416 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
10417 pub struct MerchantResponse {
10418 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
10419 pub created_at: ::std::option::Option<::std::string::String>,
10420 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
10421 pub guid: ::std::option::Option<::std::string::String>,
10422 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
10423 pub logo_url: ::std::option::Option<::std::string::String>,
10424 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
10425 pub name: ::std::option::Option<::std::string::String>,
10426 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
10427 pub updated_at: ::std::option::Option<::std::string::String>,
10428 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
10429 pub website_url: ::std::option::Option<::std::string::String>,
10430 }
10431
10432 impl ::std::convert::From<&MerchantResponse> for MerchantResponse {
10433 fn from(value: &MerchantResponse) -> Self {
10434 value.clone()
10435 }
10436 }
10437
10438 impl ::std::default::Default for MerchantResponse {
10439 fn default() -> Self {
10440 Self {
10441 created_at: Default::default(),
10442 guid: Default::default(),
10443 logo_url: Default::default(),
10444 name: Default::default(),
10445 updated_at: Default::default(),
10446 website_url: Default::default(),
10447 }
10448 }
10449 }
10450
10451 ///`MerchantResponseBody`
10452 ///
10453 /// <details><summary>JSON schema</summary>
10454 ///
10455 /// ```json
10456 ///{
10457 /// "type": "object",
10458 /// "properties": {
10459 /// "merchant": {
10460 /// "$ref": "#/components/schemas/MerchantResponse"
10461 /// }
10462 /// }
10463 ///}
10464 /// ```
10465 /// </details>
10466 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
10467 pub struct MerchantResponseBody {
10468 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
10469 pub merchant: ::std::option::Option<MerchantResponse>,
10470 }
10471
10472 impl ::std::convert::From<&MerchantResponseBody> for MerchantResponseBody {
10473 fn from(value: &MerchantResponseBody) -> Self {
10474 value.clone()
10475 }
10476 }
10477
10478 impl ::std::default::Default for MerchantResponseBody {
10479 fn default() -> Self {
10480 Self {
10481 merchant: Default::default(),
10482 }
10483 }
10484 }
10485
10486 ///`MerchantsResponseBody`
10487 ///
10488 /// <details><summary>JSON schema</summary>
10489 ///
10490 /// ```json
10491 ///{
10492 /// "type": "object",
10493 /// "properties": {
10494 /// "merchants": {
10495 /// "type": "array",
10496 /// "items": {
10497 /// "$ref": "#/components/schemas/MerchantResponse"
10498 /// }
10499 /// },
10500 /// "pagination": {
10501 /// "$ref": "#/components/schemas/PaginationResponse"
10502 /// }
10503 /// }
10504 ///}
10505 /// ```
10506 /// </details>
10507 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
10508 pub struct MerchantsResponseBody {
10509 #[serde(default, skip_serializing_if = "::std::vec::Vec::is_empty")]
10510 pub merchants: ::std::vec::Vec<MerchantResponse>,
10511 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
10512 pub pagination: ::std::option::Option<PaginationResponse>,
10513 }
10514
10515 impl ::std::convert::From<&MerchantsResponseBody> for MerchantsResponseBody {
10516 fn from(value: &MerchantsResponseBody) -> Self {
10517 value.clone()
10518 }
10519 }
10520
10521 impl ::std::default::Default for MerchantsResponseBody {
10522 fn default() -> Self {
10523 Self {
10524 merchants: Default::default(),
10525 pagination: Default::default(),
10526 }
10527 }
10528 }
10529
10530 ///`MicrodepositElements`
10531 ///
10532 /// <details><summary>JSON schema</summary>
10533 ///
10534 /// ```json
10535 ///{
10536 /// "required": [
10537 /// "account_number",
10538 /// "account_type",
10539 /// "routing_number"
10540 /// ],
10541 /// "properties": {
10542 /// "account_name": {
10543 /// "examples": [
10544 /// "My test account"
10545 /// ],
10546 /// "type": "string"
10547 /// },
10548 /// "account_number": {
10549 /// "examples": [
10550 /// "3331261"
10551 /// ],
10552 /// "type": "string"
10553 /// },
10554 /// "account_type": {
10555 /// "examples": [
10556 /// "CHECKING"
10557 /// ],
10558 /// "type": "string"
10559 /// },
10560 /// "email": {
10561 /// "examples": [
10562 /// "joshyboy2@example.com"
10563 /// ],
10564 /// "type": "string"
10565 /// },
10566 /// "first_name": {
10567 /// "examples": [
10568 /// "Joshy"
10569 /// ],
10570 /// "type": "string"
10571 /// },
10572 /// "last_name": {
10573 /// "examples": [
10574 /// "Grobanne"
10575 /// ],
10576 /// "type": "string"
10577 /// },
10578 /// "routing_number": {
10579 /// "examples": [
10580 /// "091000019"
10581 /// ],
10582 /// "type": "string"
10583 /// }
10584 /// }
10585 ///}
10586 /// ```
10587 /// </details>
10588 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
10589 pub struct MicrodepositElements {
10590 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
10591 pub account_name: ::std::option::Option<::std::string::String>,
10592 pub account_number: ::std::string::String,
10593 pub account_type: ::std::string::String,
10594 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
10595 pub email: ::std::option::Option<::std::string::String>,
10596 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
10597 pub first_name: ::std::option::Option<::std::string::String>,
10598 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
10599 pub last_name: ::std::option::Option<::std::string::String>,
10600 pub routing_number: ::std::string::String,
10601 }
10602
10603 impl ::std::convert::From<&MicrodepositElements> for MicrodepositElements {
10604 fn from(value: &MicrodepositElements) -> Self {
10605 value.clone()
10606 }
10607 }
10608
10609 ///`MicrodepositRequestBody`
10610 ///
10611 /// <details><summary>JSON schema</summary>
10612 ///
10613 /// ```json
10614 ///{
10615 /// "type": "object",
10616 /// "properties": {
10617 /// "micro_deposit": {
10618 /// "$ref": "#/components/schemas/MicrodepositElements"
10619 /// }
10620 /// }
10621 ///}
10622 /// ```
10623 /// </details>
10624 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
10625 pub struct MicrodepositRequestBody {
10626 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
10627 pub micro_deposit: ::std::option::Option<MicrodepositElements>,
10628 }
10629
10630 impl ::std::convert::From<&MicrodepositRequestBody> for MicrodepositRequestBody {
10631 fn from(value: &MicrodepositRequestBody) -> Self {
10632 value.clone()
10633 }
10634 }
10635
10636 impl ::std::default::Default for MicrodepositRequestBody {
10637 fn default() -> Self {
10638 Self {
10639 micro_deposit: Default::default(),
10640 }
10641 }
10642 }
10643
10644 ///`MicrodepositResponse`
10645 ///
10646 /// <details><summary>JSON schema</summary>
10647 ///
10648 /// ```json
10649 ///{
10650 /// "type": "object",
10651 /// "properties": {
10652 /// "error_message": {
10653 /// "type": [
10654 /// "string",
10655 /// "null"
10656 /// ]
10657 /// },
10658 /// "guid": {
10659 /// "examples": [
10660 /// "MIC-09ba578e-8448-4f7f-89e1-b62ff2517edb"
10661 /// ],
10662 /// "type": "string"
10663 /// },
10664 /// "institution_code": {
10665 /// "examples": [
10666 /// "mxbank"
10667 /// ],
10668 /// "type": "string"
10669 /// },
10670 /// "institution_name": {
10671 /// "examples": [
10672 /// "MX Bank"
10673 /// ],
10674 /// "type": "string"
10675 /// },
10676 /// "status": {
10677 /// "examples": [
10678 /// "INITIATED"
10679 /// ],
10680 /// "type": "string"
10681 /// },
10682 /// "updated_at": {
10683 /// "examples": [
10684 /// "2023-06-01T19:18:06Z"
10685 /// ],
10686 /// "type": "string"
10687 /// },
10688 /// "verified_at": {
10689 /// "type": [
10690 /// "string",
10691 /// "null"
10692 /// ]
10693 /// }
10694 /// }
10695 ///}
10696 /// ```
10697 /// </details>
10698 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
10699 pub struct MicrodepositResponse {
10700 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
10701 pub error_message: ::std::option::Option<::std::string::String>,
10702 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
10703 pub guid: ::std::option::Option<::std::string::String>,
10704 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
10705 pub institution_code: ::std::option::Option<::std::string::String>,
10706 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
10707 pub institution_name: ::std::option::Option<::std::string::String>,
10708 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
10709 pub status: ::std::option::Option<::std::string::String>,
10710 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
10711 pub updated_at: ::std::option::Option<::std::string::String>,
10712 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
10713 pub verified_at: ::std::option::Option<::std::string::String>,
10714 }
10715
10716 impl ::std::convert::From<&MicrodepositResponse> for MicrodepositResponse {
10717 fn from(value: &MicrodepositResponse) -> Self {
10718 value.clone()
10719 }
10720 }
10721
10722 impl ::std::default::Default for MicrodepositResponse {
10723 fn default() -> Self {
10724 Self {
10725 error_message: Default::default(),
10726 guid: Default::default(),
10727 institution_code: Default::default(),
10728 institution_name: Default::default(),
10729 status: Default::default(),
10730 updated_at: Default::default(),
10731 verified_at: Default::default(),
10732 }
10733 }
10734 }
10735
10736 ///`MicrodepositResponseBody`
10737 ///
10738 /// <details><summary>JSON schema</summary>
10739 ///
10740 /// ```json
10741 ///{
10742 /// "type": "object",
10743 /// "properties": {
10744 /// "micro_deposit": {
10745 /// "items": {
10746 /// "allOf": [
10747 /// {
10748 /// "$ref": "#/components/schemas/MicrodepositElements"
10749 /// },
10750 /// {
10751 /// "$ref": "#/components/schemas/MicrodepositResponse"
10752 /// }
10753 /// ]
10754 /// }
10755 /// }
10756 /// }
10757 ///}
10758 /// ```
10759 /// </details>
10760 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
10761 pub struct MicrodepositResponseBody {
10762 #[serde(default, skip_serializing_if = "::std::vec::Vec::is_empty")]
10763 pub micro_deposit: ::std::vec::Vec<MicrodepositResponseBodyMicroDepositItem>,
10764 }
10765
10766 impl ::std::convert::From<&MicrodepositResponseBody> for MicrodepositResponseBody {
10767 fn from(value: &MicrodepositResponseBody) -> Self {
10768 value.clone()
10769 }
10770 }
10771
10772 impl ::std::default::Default for MicrodepositResponseBody {
10773 fn default() -> Self {
10774 Self {
10775 micro_deposit: Default::default(),
10776 }
10777 }
10778 }
10779
10780 ///`MicrodepositResponseBodyMicroDepositItem`
10781 ///
10782 /// <details><summary>JSON schema</summary>
10783 ///
10784 /// ```json
10785 ///{
10786 /// "allOf": [
10787 /// {
10788 /// "$ref": "#/components/schemas/MicrodepositElements"
10789 /// },
10790 /// {
10791 /// "$ref": "#/components/schemas/MicrodepositResponse"
10792 /// }
10793 /// ]
10794 ///}
10795 /// ```
10796 /// </details>
10797 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
10798 pub struct MicrodepositResponseBodyMicroDepositItem {
10799 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
10800 pub account_name: ::std::option::Option<::std::string::String>,
10801 pub account_number: ::std::string::String,
10802 pub account_type: ::std::string::String,
10803 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
10804 pub email: ::std::option::Option<::std::string::String>,
10805 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
10806 pub error_message: ::std::option::Option<::std::string::String>,
10807 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
10808 pub first_name: ::std::option::Option<::std::string::String>,
10809 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
10810 pub guid: ::std::option::Option<::std::string::String>,
10811 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
10812 pub institution_code: ::std::option::Option<::std::string::String>,
10813 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
10814 pub institution_name: ::std::option::Option<::std::string::String>,
10815 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
10816 pub last_name: ::std::option::Option<::std::string::String>,
10817 pub routing_number: ::std::string::String,
10818 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
10819 pub status: ::std::option::Option<::std::string::String>,
10820 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
10821 pub updated_at: ::std::option::Option<::std::string::String>,
10822 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
10823 pub verified_at: ::std::option::Option<::std::string::String>,
10824 }
10825
10826 impl ::std::convert::From<&MicrodepositResponseBodyMicroDepositItem>
10827 for MicrodepositResponseBodyMicroDepositItem
10828 {
10829 fn from(value: &MicrodepositResponseBodyMicroDepositItem) -> Self {
10830 value.clone()
10831 }
10832 }
10833
10834 ///`MicrodepositVerifyRequest`
10835 ///
10836 /// <details><summary>JSON schema</summary>
10837 ///
10838 /// ```json
10839 ///{
10840 /// "type": "object",
10841 /// "properties": {
10842 /// "deposit_amount_1": {
10843 /// "examples": [
10844 /// 0.09
10845 /// ],
10846 /// "type": "number"
10847 /// },
10848 /// "deposit_amount_2": {
10849 /// "examples": [
10850 /// 0.09
10851 /// ],
10852 /// "type": "number"
10853 /// }
10854 /// }
10855 ///}
10856 /// ```
10857 /// </details>
10858 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
10859 pub struct MicrodepositVerifyRequest {
10860 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
10861 pub deposit_amount_1: ::std::option::Option<f64>,
10862 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
10863 pub deposit_amount_2: ::std::option::Option<f64>,
10864 }
10865
10866 impl ::std::convert::From<&MicrodepositVerifyRequest> for MicrodepositVerifyRequest {
10867 fn from(value: &MicrodepositVerifyRequest) -> Self {
10868 value.clone()
10869 }
10870 }
10871
10872 impl ::std::default::Default for MicrodepositVerifyRequest {
10873 fn default() -> Self {
10874 Self {
10875 deposit_amount_1: Default::default(),
10876 deposit_amount_2: Default::default(),
10877 }
10878 }
10879 }
10880
10881 ///`MicrodepositVerifyRequestBody`
10882 ///
10883 /// <details><summary>JSON schema</summary>
10884 ///
10885 /// ```json
10886 ///{
10887 /// "type": "object",
10888 /// "properties": {
10889 /// "micro_deposit": {
10890 /// "$ref": "#/components/schemas/MicrodepositVerifyRequest"
10891 /// }
10892 /// }
10893 ///}
10894 /// ```
10895 /// </details>
10896 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
10897 pub struct MicrodepositVerifyRequestBody {
10898 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
10899 pub micro_deposit: ::std::option::Option<MicrodepositVerifyRequest>,
10900 }
10901
10902 impl ::std::convert::From<&MicrodepositVerifyRequestBody> for MicrodepositVerifyRequestBody {
10903 fn from(value: &MicrodepositVerifyRequestBody) -> Self {
10904 value.clone()
10905 }
10906 }
10907
10908 impl ::std::default::Default for MicrodepositVerifyRequestBody {
10909 fn default() -> Self {
10910 Self {
10911 micro_deposit: Default::default(),
10912 }
10913 }
10914 }
10915
10916 ///`MicrodepositsResponseBody`
10917 ///
10918 /// <details><summary>JSON schema</summary>
10919 ///
10920 /// ```json
10921 ///{
10922 /// "type": "object",
10923 /// "properties": {
10924 /// "micro_deposits": {
10925 /// "type": "array",
10926 /// "items": {
10927 /// "$ref": "#/components/schemas/MicrodepositResponse"
10928 /// }
10929 /// },
10930 /// "pagination": {
10931 /// "$ref": "#/components/schemas/PaginationResponse"
10932 /// }
10933 /// }
10934 ///}
10935 /// ```
10936 /// </details>
10937 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
10938 pub struct MicrodepositsResponseBody {
10939 #[serde(default, skip_serializing_if = "::std::vec::Vec::is_empty")]
10940 pub micro_deposits: ::std::vec::Vec<MicrodepositResponse>,
10941 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
10942 pub pagination: ::std::option::Option<PaginationResponse>,
10943 }
10944
10945 impl ::std::convert::From<&MicrodepositsResponseBody> for MicrodepositsResponseBody {
10946 fn from(value: &MicrodepositsResponseBody) -> Self {
10947 value.clone()
10948 }
10949 }
10950
10951 impl ::std::default::Default for MicrodepositsResponseBody {
10952 fn default() -> Self {
10953 Self {
10954 micro_deposits: Default::default(),
10955 pagination: Default::default(),
10956 }
10957 }
10958 }
10959
10960 ///`MonthlyCashFlowProfileRequest`
10961 ///
10962 /// <details><summary>JSON schema</summary>
10963 ///
10964 /// ```json
10965 ///{
10966 /// "properties": {
10967 /// "goals_contribution": {
10968 /// "description": "The monthly dollar amount allocated for goals.",
10969 /// "examples": [
10970 /// 150.01
10971 /// ],
10972 /// "type": "number"
10973 /// },
10974 /// "uses_estimated_goals_contribution": {
10975 /// "description": "Determines if the user uses estimated goals
10976 /// contribution.",
10977 /// "examples": [
10978 /// false
10979 /// ],
10980 /// "type": "boolean"
10981 /// }
10982 /// }
10983 ///}
10984 /// ```
10985 /// </details>
10986 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
10987 pub struct MonthlyCashFlowProfileRequest {
10988 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
10989 pub goals_contribution: ::std::option::Option<f64>,
10990 ///Determines if the user uses estimated goals contribution.
10991 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
10992 pub uses_estimated_goals_contribution: ::std::option::Option<bool>,
10993 }
10994
10995 impl ::std::convert::From<&MonthlyCashFlowProfileRequest> for MonthlyCashFlowProfileRequest {
10996 fn from(value: &MonthlyCashFlowProfileRequest) -> Self {
10997 value.clone()
10998 }
10999 }
11000
11001 impl ::std::default::Default for MonthlyCashFlowProfileRequest {
11002 fn default() -> Self {
11003 Self {
11004 goals_contribution: Default::default(),
11005 uses_estimated_goals_contribution: Default::default(),
11006 }
11007 }
11008 }
11009
11010 ///`MonthlyCashFlowProfileRequestBody`
11011 ///
11012 /// <details><summary>JSON schema</summary>
11013 ///
11014 /// ```json
11015 ///{
11016 /// "type": "object",
11017 /// "properties": {
11018 /// "institution": {
11019 /// "$ref": "#/components/schemas/MonthlyCashFlowProfileRequest"
11020 /// }
11021 /// }
11022 ///}
11023 /// ```
11024 /// </details>
11025 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
11026 pub struct MonthlyCashFlowProfileRequestBody {
11027 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
11028 pub institution: ::std::option::Option<MonthlyCashFlowProfileRequest>,
11029 }
11030
11031 impl ::std::convert::From<&MonthlyCashFlowProfileRequestBody>
11032 for MonthlyCashFlowProfileRequestBody
11033 {
11034 fn from(value: &MonthlyCashFlowProfileRequestBody) -> Self {
11035 value.clone()
11036 }
11037 }
11038
11039 impl ::std::default::Default for MonthlyCashFlowProfileRequestBody {
11040 fn default() -> Self {
11041 Self {
11042 institution: Default::default(),
11043 }
11044 }
11045 }
11046
11047 ///`MonthlyCashFlowResponse`
11048 ///
11049 /// <details><summary>JSON schema</summary>
11050 ///
11051 /// ```json
11052 ///{
11053 /// "properties": {
11054 /// "budgeted_expenses": {
11055 /// "description": "The amount of the budgeted expenses for the user.",
11056 /// "examples": [
11057 /// 1000
11058 /// ],
11059 /// "type": "number"
11060 /// },
11061 /// "budgeted_income": {
11062 /// "description": "The amount of the budgeted income for the user.",
11063 /// "examples": [
11064 /// 1200.12
11065 /// ],
11066 /// "type": "number"
11067 /// },
11068 /// "estimated_goals_contribution": {
11069 /// "description": "The estimated monthly dollar amount allocated for
11070 /// goals calculated from income and budgets.",
11071 /// "type": [
11072 /// "number",
11073 /// "null"
11074 /// ]
11075 /// },
11076 /// "goals_contribution": {
11077 /// "description": "The monthly dollar amount allocated for goals.",
11078 /// "examples": [
11079 /// 150
11080 /// ],
11081 /// "type": "number"
11082 /// },
11083 /// "guid": {
11084 /// "description": "Unique identifier for the monthly cash flow
11085 /// profile. Defined by MX.",
11086 /// "examples": [
11087 /// "MCF-4e431124-4a29-abf9-f059-ab232ac14dbf"
11088 /// ],
11089 /// "type": "string"
11090 /// },
11091 /// "user_guid": {
11092 /// "description": "Unique identifier for the user the monthly cash
11093 /// flow profile is attached to. Defined by MX.",
11094 /// "examples": [
11095 /// "USR-6c83f63c-efcc-0189-3f14-100f0bad378a"
11096 /// ],
11097 /// "type": "string"
11098 /// },
11099 /// "uses_estimated_goals_contribution": {
11100 /// "examples": [
11101 /// false
11102 /// ],
11103 /// "type": "boolean"
11104 /// }
11105 /// }
11106 ///}
11107 /// ```
11108 /// </details>
11109 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
11110 pub struct MonthlyCashFlowResponse {
11111 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
11112 pub budgeted_expenses: ::std::option::Option<f64>,
11113 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
11114 pub budgeted_income: ::std::option::Option<f64>,
11115 ///The estimated monthly dollar amount allocated for goals calculated
11116 /// from income and budgets.
11117 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
11118 pub estimated_goals_contribution: ::std::option::Option<f64>,
11119 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
11120 pub goals_contribution: ::std::option::Option<f64>,
11121 ///Unique identifier for the monthly cash flow profile. Defined by MX.
11122 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
11123 pub guid: ::std::option::Option<::std::string::String>,
11124 ///Unique identifier for the user the monthly cash flow profile is
11125 /// attached to. Defined by MX.
11126 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
11127 pub user_guid: ::std::option::Option<::std::string::String>,
11128 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
11129 pub uses_estimated_goals_contribution: ::std::option::Option<bool>,
11130 }
11131
11132 impl ::std::convert::From<&MonthlyCashFlowResponse> for MonthlyCashFlowResponse {
11133 fn from(value: &MonthlyCashFlowResponse) -> Self {
11134 value.clone()
11135 }
11136 }
11137
11138 impl ::std::default::Default for MonthlyCashFlowResponse {
11139 fn default() -> Self {
11140 Self {
11141 budgeted_expenses: Default::default(),
11142 budgeted_income: Default::default(),
11143 estimated_goals_contribution: Default::default(),
11144 goals_contribution: Default::default(),
11145 guid: Default::default(),
11146 user_guid: Default::default(),
11147 uses_estimated_goals_contribution: Default::default(),
11148 }
11149 }
11150 }
11151
11152 ///`MonthlyCashFlowResponseBody`
11153 ///
11154 /// <details><summary>JSON schema</summary>
11155 ///
11156 /// ```json
11157 ///{
11158 /// "type": "object",
11159 /// "properties": {
11160 /// "monthly_cash_flow_profile": {
11161 /// "$ref": "#/components/schemas/MonthlyCashFlowResponse"
11162 /// }
11163 /// }
11164 ///}
11165 /// ```
11166 /// </details>
11167 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
11168 pub struct MonthlyCashFlowResponseBody {
11169 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
11170 pub monthly_cash_flow_profile: ::std::option::Option<MonthlyCashFlowResponse>,
11171 }
11172
11173 impl ::std::convert::From<&MonthlyCashFlowResponseBody> for MonthlyCashFlowResponseBody {
11174 fn from(value: &MonthlyCashFlowResponseBody) -> Self {
11175 value.clone()
11176 }
11177 }
11178
11179 impl ::std::default::Default for MonthlyCashFlowResponseBody {
11180 fn default() -> Self {
11181 Self {
11182 monthly_cash_flow_profile: Default::default(),
11183 }
11184 }
11185 }
11186
11187 ///`NotificationResponse`
11188 ///
11189 /// <details><summary>JSON schema</summary>
11190 ///
11191 /// ```json
11192 ///{
11193 /// "properties": {
11194 /// "channel": {
11195 /// "examples": [
11196 /// "push"
11197 /// ]
11198 /// },
11199 /// "content": {
11200 /// "examples": [
11201 /// "The content related to the notification."
11202 /// ]
11203 /// },
11204 /// "deep_link_guid": {
11205 /// "examples": [
11206 /// "BGT-e386a323-e452-47f2-b2fd-1ac3c18533de"
11207 /// ]
11208 /// },
11209 /// "delivered_at": {},
11210 /// "entity_guid": {
11211 /// "examples": [
11212 /// "BGT-e386a323-e452-47f2-b2fd-1ac3c18533de"
11213 /// ]
11214 /// },
11215 /// "guid": {
11216 /// "examples": [
11217 /// "TF-b53294f5-2356-4782-9f81-ae064c42b40a"
11218 /// ]
11219 /// },
11220 /// "has_been_delivered": {
11221 /// "examples": [
11222 /// true
11223 /// ]
11224 /// },
11225 /// "has_been_viewed": {
11226 /// "examples": [
11227 /// false
11228 /// ]
11229 /// },
11230 /// "notification_type": {
11231 /// "examples": [
11232 /// 2
11233 /// ]
11234 /// },
11235 /// "subject": {
11236 /// "examples": [
11237 /// "You're projected to spend $1,920.07 more than you've budgeted
11238 /// for Fees & Charges. You've already spent $65.67 of $316.00."
11239 /// ]
11240 /// }
11241 /// }
11242 ///}
11243 /// ```
11244 /// </details>
11245 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
11246 pub struct NotificationResponse {
11247 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
11248 pub channel: ::std::option::Option<::serde_json::Value>,
11249 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
11250 pub content: ::std::option::Option<::serde_json::Value>,
11251 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
11252 pub deep_link_guid: ::std::option::Option<::serde_json::Value>,
11253 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
11254 pub delivered_at: ::std::option::Option<::serde_json::Value>,
11255 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
11256 pub entity_guid: ::std::option::Option<::serde_json::Value>,
11257 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
11258 pub guid: ::std::option::Option<::serde_json::Value>,
11259 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
11260 pub has_been_delivered: ::std::option::Option<::serde_json::Value>,
11261 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
11262 pub has_been_viewed: ::std::option::Option<::serde_json::Value>,
11263 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
11264 pub notification_type: ::std::option::Option<::serde_json::Value>,
11265 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
11266 pub subject: ::std::option::Option<::serde_json::Value>,
11267 }
11268
11269 impl ::std::convert::From<&NotificationResponse> for NotificationResponse {
11270 fn from(value: &NotificationResponse) -> Self {
11271 value.clone()
11272 }
11273 }
11274
11275 impl ::std::default::Default for NotificationResponse {
11276 fn default() -> Self {
11277 Self {
11278 channel: Default::default(),
11279 content: Default::default(),
11280 deep_link_guid: Default::default(),
11281 delivered_at: Default::default(),
11282 entity_guid: Default::default(),
11283 guid: Default::default(),
11284 has_been_delivered: Default::default(),
11285 has_been_viewed: Default::default(),
11286 notification_type: Default::default(),
11287 subject: Default::default(),
11288 }
11289 }
11290 }
11291
11292 ///`NotificationResponseBody`
11293 ///
11294 /// <details><summary>JSON schema</summary>
11295 ///
11296 /// ```json
11297 ///{
11298 /// "type": "object",
11299 /// "properties": {
11300 /// "notification": {
11301 /// "$ref": "#/components/schemas/NotificationResponse"
11302 /// }
11303 /// }
11304 ///}
11305 /// ```
11306 /// </details>
11307 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
11308 pub struct NotificationResponseBody {
11309 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
11310 pub notification: ::std::option::Option<NotificationResponse>,
11311 }
11312
11313 impl ::std::convert::From<&NotificationResponseBody> for NotificationResponseBody {
11314 fn from(value: &NotificationResponseBody) -> Self {
11315 value.clone()
11316 }
11317 }
11318
11319 impl ::std::default::Default for NotificationResponseBody {
11320 fn default() -> Self {
11321 Self {
11322 notification: Default::default(),
11323 }
11324 }
11325 }
11326
11327 ///`NotificationsResponseBody`
11328 ///
11329 /// <details><summary>JSON schema</summary>
11330 ///
11331 /// ```json
11332 ///{
11333 /// "type": "object",
11334 /// "properties": {
11335 /// "notifications": {
11336 /// "items": {
11337 /// "$ref": "#/components/schemas/NotificationResponse"
11338 /// }
11339 /// }
11340 /// }
11341 ///}
11342 /// ```
11343 /// </details>
11344 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
11345 pub struct NotificationsResponseBody {
11346 #[serde(default, skip_serializing_if = "::std::vec::Vec::is_empty")]
11347 pub notifications: ::std::vec::Vec<NotificationResponse>,
11348 }
11349
11350 impl ::std::convert::From<&NotificationsResponseBody> for NotificationsResponseBody {
11351 fn from(value: &NotificationsResponseBody) -> Self {
11352 value.clone()
11353 }
11354 }
11355
11356 impl ::std::default::Default for NotificationsResponseBody {
11357 fn default() -> Self {
11358 Self {
11359 notifications: Default::default(),
11360 }
11361 }
11362 }
11363
11364 ///`OAuthWindowResponse`
11365 ///
11366 /// <details><summary>JSON schema</summary>
11367 ///
11368 /// ```json
11369 ///{
11370 /// "type": "object",
11371 /// "properties": {
11372 /// "guid": {
11373 /// "examples": [
11374 /// "MBR-df96fd60-7122-4464-b3c2-ff11d8c74f6f"
11375 /// ],
11376 /// "type": [
11377 /// "string",
11378 /// "null"
11379 /// ]
11380 /// },
11381 /// "oauth_window_uri": {
11382 /// "examples": [
11383 /// "https://mxbank.mx.com/oauth/authorize?client_id=b8OikQ4Ep3NuSUrQ13DdvFuwpNx-qqoAsJDVAQCyLkQ&redirect_uri=https%3A%2F%2Fint-app.moneydesktop.com%2Foauth%2Fredirect_from&response_type=code&scope=openid&state=d745bd4ee6f0f9c184757f574bcc2df2"
11384 /// ],
11385 /// "type": [
11386 /// "string",
11387 /// "null"
11388 /// ]
11389 /// }
11390 /// }
11391 ///}
11392 /// ```
11393 /// </details>
11394 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
11395 pub struct OAuthWindowResponse {
11396 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
11397 pub guid: ::std::option::Option<::std::string::String>,
11398 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
11399 pub oauth_window_uri: ::std::option::Option<::std::string::String>,
11400 }
11401
11402 impl ::std::convert::From<&OAuthWindowResponse> for OAuthWindowResponse {
11403 fn from(value: &OAuthWindowResponse) -> Self {
11404 value.clone()
11405 }
11406 }
11407
11408 impl ::std::default::Default for OAuthWindowResponse {
11409 fn default() -> Self {
11410 Self {
11411 guid: Default::default(),
11412 oauth_window_uri: Default::default(),
11413 }
11414 }
11415 }
11416
11417 ///`OAuthWindowResponseBody`
11418 ///
11419 /// <details><summary>JSON schema</summary>
11420 ///
11421 /// ```json
11422 ///{
11423 /// "type": "object",
11424 /// "properties": {
11425 /// "member": {
11426 /// "$ref": "#/components/schemas/OAuthWindowResponse"
11427 /// }
11428 /// }
11429 ///}
11430 /// ```
11431 /// </details>
11432 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
11433 pub struct OAuthWindowResponseBody {
11434 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
11435 pub member: ::std::option::Option<OAuthWindowResponse>,
11436 }
11437
11438 impl ::std::convert::From<&OAuthWindowResponseBody> for OAuthWindowResponseBody {
11439 fn from(value: &OAuthWindowResponseBody) -> Self {
11440 value.clone()
11441 }
11442 }
11443
11444 impl ::std::default::Default for OAuthWindowResponseBody {
11445 fn default() -> Self {
11446 Self {
11447 member: Default::default(),
11448 }
11449 }
11450 }
11451
11452 ///`OptionResponse`
11453 ///
11454 /// <details><summary>JSON schema</summary>
11455 ///
11456 /// ```json
11457 ///{
11458 /// "type": "object",
11459 /// "properties": {
11460 /// "guid": {
11461 /// "examples": [
11462 /// "CRD-ce76d2e3-86bd-ec4a-ec52-eb53b5194bf5"
11463 /// ],
11464 /// "type": [
11465 /// "string",
11466 /// "null"
11467 /// ]
11468 /// },
11469 /// "label": {
11470 /// "examples": [
11471 /// "IMAGE_1"
11472 /// ],
11473 /// "type": [
11474 /// "string",
11475 /// "null"
11476 /// ]
11477 /// },
11478 /// "value": {
11479 /// "examples": [
11480 /// "image_data"
11481 /// ],
11482 /// "type": [
11483 /// "string",
11484 /// "null"
11485 /// ]
11486 /// }
11487 /// }
11488 ///}
11489 /// ```
11490 /// </details>
11491 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
11492 pub struct OptionResponse {
11493 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
11494 pub guid: ::std::option::Option<::std::string::String>,
11495 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
11496 pub label: ::std::option::Option<::std::string::String>,
11497 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
11498 pub value: ::std::option::Option<::std::string::String>,
11499 }
11500
11501 impl ::std::convert::From<&OptionResponse> for OptionResponse {
11502 fn from(value: &OptionResponse) -> Self {
11503 value.clone()
11504 }
11505 }
11506
11507 impl ::std::default::Default for OptionResponse {
11508 fn default() -> Self {
11509 Self {
11510 guid: Default::default(),
11511 label: Default::default(),
11512 value: Default::default(),
11513 }
11514 }
11515 }
11516
11517 ///`PaginationResponse`
11518 ///
11519 /// <details><summary>JSON schema</summary>
11520 ///
11521 /// ```json
11522 ///{
11523 /// "type": "object",
11524 /// "properties": {
11525 /// "current_page": {
11526 /// "examples": [
11527 /// 1
11528 /// ],
11529 /// "type": "integer"
11530 /// },
11531 /// "per_page": {
11532 /// "examples": [
11533 /// 25
11534 /// ],
11535 /// "type": "integer"
11536 /// },
11537 /// "total_entries": {
11538 /// "examples": [
11539 /// 1
11540 /// ],
11541 /// "type": "integer"
11542 /// },
11543 /// "total_pages": {
11544 /// "examples": [
11545 /// 1
11546 /// ],
11547 /// "type": "integer"
11548 /// }
11549 /// }
11550 ///}
11551 /// ```
11552 /// </details>
11553 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
11554 pub struct PaginationResponse {
11555 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
11556 pub current_page: ::std::option::Option<i64>,
11557 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
11558 pub per_page: ::std::option::Option<i64>,
11559 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
11560 pub total_entries: ::std::option::Option<i64>,
11561 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
11562 pub total_pages: ::std::option::Option<i64>,
11563 }
11564
11565 impl ::std::convert::From<&PaginationResponse> for PaginationResponse {
11566 fn from(value: &PaginationResponse) -> Self {
11567 value.clone()
11568 }
11569 }
11570
11571 impl ::std::default::Default for PaginationResponse {
11572 fn default() -> Self {
11573 Self {
11574 current_page: Default::default(),
11575 per_page: Default::default(),
11576 total_entries: Default::default(),
11577 total_pages: Default::default(),
11578 }
11579 }
11580 }
11581
11582 ///`PaymentAccount`
11583 ///
11584 /// <details><summary>JSON schema</summary>
11585 ///
11586 /// ```json
11587 ///{
11588 /// "properties": {
11589 /// "account_name": {
11590 /// "examples": [
11591 /// "MX Bank Checking"
11592 /// ]
11593 /// },
11594 /// "account_number": {
11595 /// "examples": [
11596 /// 6366816006
11597 /// ]
11598 /// },
11599 /// "account_type": {
11600 /// "examples": [
11601 /// "CHECKING"
11602 /// ]
11603 /// },
11604 /// "available_balance": {
11605 /// "examples": [
11606 /// 1000
11607 /// ]
11608 /// },
11609 /// "balance": {
11610 /// "examples": [
11611 /// 1000
11612 /// ]
11613 /// },
11614 /// "created_at": {
11615 /// "examples": [
11616 /// "2022-03-17T20:38:58Z"
11617 /// ]
11618 /// },
11619 /// "routing_number": {
11620 /// "examples": [
11621 /// 242722023
11622 /// ]
11623 /// },
11624 /// "transit_number": {},
11625 /// "updated_at": {
11626 /// "examples": [
11627 /// "2022-11-29T08:02:07Z"
11628 /// ]
11629 /// }
11630 /// }
11631 ///}
11632 /// ```
11633 /// </details>
11634 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
11635 pub struct PaymentAccount {
11636 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
11637 pub account_name: ::std::option::Option<::serde_json::Value>,
11638 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
11639 pub account_number: ::std::option::Option<::serde_json::Value>,
11640 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
11641 pub account_type: ::std::option::Option<::serde_json::Value>,
11642 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
11643 pub available_balance: ::std::option::Option<::serde_json::Value>,
11644 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
11645 pub balance: ::std::option::Option<::serde_json::Value>,
11646 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
11647 pub created_at: ::std::option::Option<::serde_json::Value>,
11648 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
11649 pub routing_number: ::std::option::Option<::serde_json::Value>,
11650 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
11651 pub transit_number: ::std::option::Option<::serde_json::Value>,
11652 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
11653 pub updated_at: ::std::option::Option<::serde_json::Value>,
11654 }
11655
11656 impl ::std::convert::From<&PaymentAccount> for PaymentAccount {
11657 fn from(value: &PaymentAccount) -> Self {
11658 value.clone()
11659 }
11660 }
11661
11662 impl ::std::default::Default for PaymentAccount {
11663 fn default() -> Self {
11664 Self {
11665 account_name: Default::default(),
11666 account_number: Default::default(),
11667 account_type: Default::default(),
11668 available_balance: Default::default(),
11669 balance: Default::default(),
11670 created_at: Default::default(),
11671 routing_number: Default::default(),
11672 transit_number: Default::default(),
11673 updated_at: Default::default(),
11674 }
11675 }
11676 }
11677
11678 ///`PaymentAccountBody`
11679 ///
11680 /// <details><summary>JSON schema</summary>
11681 ///
11682 /// ```json
11683 ///{
11684 /// "type": "object",
11685 /// "properties": {
11686 /// "payment_account": {
11687 /// "allOf": [
11688 /// {
11689 /// "$ref": "#/components/schemas/MemberElements"
11690 /// },
11691 /// {
11692 /// "$ref": "#/components/schemas/PaymentAccount"
11693 /// }
11694 /// ]
11695 /// }
11696 /// }
11697 ///}
11698 /// ```
11699 /// </details>
11700 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
11701 pub struct PaymentAccountBody {
11702 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
11703 pub payment_account: ::std::option::Option<PaymentAccountBodyPaymentAccount>,
11704 }
11705
11706 impl ::std::convert::From<&PaymentAccountBody> for PaymentAccountBody {
11707 fn from(value: &PaymentAccountBody) -> Self {
11708 value.clone()
11709 }
11710 }
11711
11712 impl ::std::default::Default for PaymentAccountBody {
11713 fn default() -> Self {
11714 Self {
11715 payment_account: Default::default(),
11716 }
11717 }
11718 }
11719
11720 ///`PaymentAccountBodyPaymentAccount`
11721 ///
11722 /// <details><summary>JSON schema</summary>
11723 ///
11724 /// ```json
11725 ///{
11726 /// "allOf": [
11727 /// {
11728 /// "$ref": "#/components/schemas/MemberElements"
11729 /// },
11730 /// {
11731 /// "$ref": "#/components/schemas/PaymentAccount"
11732 /// }
11733 /// ]
11734 ///}
11735 /// ```
11736 /// </details>
11737 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
11738 pub struct PaymentAccountBodyPaymentAccount {
11739 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
11740 pub account_guid: ::std::option::Option<::std::string::String>,
11741 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
11742 pub account_name: ::std::option::Option<::serde_json::Value>,
11743 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
11744 pub account_number: ::std::option::Option<::serde_json::Value>,
11745 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
11746 pub account_type: ::std::option::Option<::serde_json::Value>,
11747 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
11748 pub available_balance: ::std::option::Option<::serde_json::Value>,
11749 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
11750 pub balance: ::std::option::Option<::serde_json::Value>,
11751 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
11752 pub created_at: ::std::option::Option<::serde_json::Value>,
11753 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
11754 pub member_guid: ::std::option::Option<::std::string::String>,
11755 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
11756 pub routing_number: ::std::option::Option<::serde_json::Value>,
11757 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
11758 pub transit_number: ::std::option::Option<::serde_json::Value>,
11759 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
11760 pub updated_at: ::std::option::Option<::serde_json::Value>,
11761 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
11762 pub user_guid: ::std::option::Option<::std::string::String>,
11763 }
11764
11765 impl ::std::convert::From<&PaymentAccountBodyPaymentAccount> for PaymentAccountBodyPaymentAccount {
11766 fn from(value: &PaymentAccountBodyPaymentAccount) -> Self {
11767 value.clone()
11768 }
11769 }
11770
11771 impl ::std::default::Default for PaymentAccountBodyPaymentAccount {
11772 fn default() -> Self {
11773 Self {
11774 account_guid: Default::default(),
11775 account_name: Default::default(),
11776 account_number: Default::default(),
11777 account_type: Default::default(),
11778 available_balance: Default::default(),
11779 balance: Default::default(),
11780 created_at: Default::default(),
11781 member_guid: Default::default(),
11782 routing_number: Default::default(),
11783 transit_number: Default::default(),
11784 updated_at: Default::default(),
11785 user_guid: Default::default(),
11786 }
11787 }
11788 }
11789
11790 ///`PaymentProcessorAuthorizationCodeRequest`
11791 ///
11792 /// <details><summary>JSON schema</summary>
11793 ///
11794 /// ```json
11795 ///{
11796 /// "type": "object",
11797 /// "required": [
11798 /// "account_guid",
11799 /// "member_guid",
11800 /// "user_guid"
11801 /// ],
11802 /// "properties": {
11803 /// "account_guid": {
11804 /// "examples": [
11805 /// "ACT-4d4c0068-33bc-4d06-bbd6-cd270fd0135c"
11806 /// ],
11807 /// "type": "string"
11808 /// },
11809 /// "member_guid": {
11810 /// "examples": [
11811 /// "MBR-46637bc5-942d-4229-9370-ddd858bf805e"
11812 /// ],
11813 /// "type": "string"
11814 /// },
11815 /// "user_guid": {
11816 /// "examples": [
11817 /// "USR-f12b1f5a-7cbe-467c-aa30-0a10d0b2f549"
11818 /// ],
11819 /// "type": "string"
11820 /// }
11821 /// }
11822 ///}
11823 /// ```
11824 /// </details>
11825 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
11826 pub struct PaymentProcessorAuthorizationCodeRequest {
11827 pub account_guid: ::std::string::String,
11828 pub member_guid: ::std::string::String,
11829 pub user_guid: ::std::string::String,
11830 }
11831
11832 impl ::std::convert::From<&PaymentProcessorAuthorizationCodeRequest>
11833 for PaymentProcessorAuthorizationCodeRequest
11834 {
11835 fn from(value: &PaymentProcessorAuthorizationCodeRequest) -> Self {
11836 value.clone()
11837 }
11838 }
11839
11840 ///`PaymentProcessorAuthorizationCodeRequestBody`
11841 ///
11842 /// <details><summary>JSON schema</summary>
11843 ///
11844 /// ```json
11845 ///{
11846 /// "type": "object",
11847 /// "properties": {
11848 /// "payment_processor_authorization_code": {
11849 /// "$ref":
11850 /// "#/components/schemas/PaymentProcessorAuthorizationCodeRequest"
11851 /// }
11852 /// }
11853 ///}
11854 /// ```
11855 /// </details>
11856 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
11857 pub struct PaymentProcessorAuthorizationCodeRequestBody {
11858 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
11859 pub payment_processor_authorization_code:
11860 ::std::option::Option<PaymentProcessorAuthorizationCodeRequest>,
11861 }
11862
11863 impl ::std::convert::From<&PaymentProcessorAuthorizationCodeRequestBody>
11864 for PaymentProcessorAuthorizationCodeRequestBody
11865 {
11866 fn from(value: &PaymentProcessorAuthorizationCodeRequestBody) -> Self {
11867 value.clone()
11868 }
11869 }
11870
11871 impl ::std::default::Default for PaymentProcessorAuthorizationCodeRequestBody {
11872 fn default() -> Self {
11873 Self {
11874 payment_processor_authorization_code: Default::default(),
11875 }
11876 }
11877 }
11878
11879 ///`PaymentProcessorAuthorizationCodeResponse`
11880 ///
11881 /// <details><summary>JSON schema</summary>
11882 ///
11883 /// ```json
11884 ///{
11885 /// "type": "object",
11886 /// "properties": {
11887 /// "authorization_code": {
11888 /// "examples": [
11889 /// "9nN-9D8_4Z3WYazx7-zXfmqsD3jwgL_2W927Sb3otI"
11890 /// ],
11891 /// "type": [
11892 /// "string",
11893 /// "null"
11894 /// ]
11895 /// }
11896 /// }
11897 ///}
11898 /// ```
11899 /// </details>
11900 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
11901 pub struct PaymentProcessorAuthorizationCodeResponse {
11902 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
11903 pub authorization_code: ::std::option::Option<::std::string::String>,
11904 }
11905
11906 impl ::std::convert::From<&PaymentProcessorAuthorizationCodeResponse>
11907 for PaymentProcessorAuthorizationCodeResponse
11908 {
11909 fn from(value: &PaymentProcessorAuthorizationCodeResponse) -> Self {
11910 value.clone()
11911 }
11912 }
11913
11914 impl ::std::default::Default for PaymentProcessorAuthorizationCodeResponse {
11915 fn default() -> Self {
11916 Self {
11917 authorization_code: Default::default(),
11918 }
11919 }
11920 }
11921
11922 ///`PaymentProcessorAuthorizationCodeResponseBody`
11923 ///
11924 /// <details><summary>JSON schema</summary>
11925 ///
11926 /// ```json
11927 ///{
11928 /// "type": "object",
11929 /// "properties": {
11930 /// "payment_processor_authorization_code": {
11931 /// "$ref":
11932 /// "#/components/schemas/PaymentProcessorAuthorizationCodeResponse"
11933 /// }
11934 /// }
11935 ///}
11936 /// ```
11937 /// </details>
11938 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
11939 pub struct PaymentProcessorAuthorizationCodeResponseBody {
11940 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
11941 pub payment_processor_authorization_code:
11942 ::std::option::Option<PaymentProcessorAuthorizationCodeResponse>,
11943 }
11944
11945 impl ::std::convert::From<&PaymentProcessorAuthorizationCodeResponseBody>
11946 for PaymentProcessorAuthorizationCodeResponseBody
11947 {
11948 fn from(value: &PaymentProcessorAuthorizationCodeResponseBody) -> Self {
11949 value.clone()
11950 }
11951 }
11952
11953 impl ::std::default::Default for PaymentProcessorAuthorizationCodeResponseBody {
11954 fn default() -> Self {
11955 Self {
11956 payment_processor_authorization_code: Default::default(),
11957 }
11958 }
11959 }
11960
11961 ///`ProcessorAccountNumber`
11962 ///
11963 /// <details><summary>JSON schema</summary>
11964 ///
11965 /// ```json
11966 ///{
11967 /// "properties": {
11968 /// "account_number": {
11969 /// "examples": [
11970 /// 6366816006
11971 /// ],
11972 /// "type": "integer"
11973 /// },
11974 /// "guid": {
11975 /// "examples": [
11976 /// "ACN-68c0b681-78c2-4731-9b41-d6e8ae2846cf"
11977 /// ],
11978 /// "type": "string"
11979 /// },
11980 /// "institution_number": {},
11981 /// "loan_guarantor": {},
11982 /// "loan_reference_number": {},
11983 /// "passed_validation": {
11984 /// "examples": [
11985 /// true
11986 /// ]
11987 /// },
11988 /// "routing_number": {
11989 /// "examples": [
11990 /// 242564563
11991 /// ],
11992 /// "type": "integer"
11993 /// },
11994 /// "sequence_number": {},
11995 /// "transit_number": {}
11996 /// }
11997 ///}
11998 /// ```
11999 /// </details>
12000 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
12001 pub struct ProcessorAccountNumber {
12002 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
12003 pub account_number: ::std::option::Option<i64>,
12004 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
12005 pub guid: ::std::option::Option<::std::string::String>,
12006 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
12007 pub institution_number: ::std::option::Option<::serde_json::Value>,
12008 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
12009 pub loan_guarantor: ::std::option::Option<::serde_json::Value>,
12010 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
12011 pub loan_reference_number: ::std::option::Option<::serde_json::Value>,
12012 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
12013 pub passed_validation: ::std::option::Option<::serde_json::Value>,
12014 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
12015 pub routing_number: ::std::option::Option<i64>,
12016 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
12017 pub sequence_number: ::std::option::Option<::serde_json::Value>,
12018 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
12019 pub transit_number: ::std::option::Option<::serde_json::Value>,
12020 }
12021
12022 impl ::std::convert::From<&ProcessorAccountNumber> for ProcessorAccountNumber {
12023 fn from(value: &ProcessorAccountNumber) -> Self {
12024 value.clone()
12025 }
12026 }
12027
12028 impl ::std::default::Default for ProcessorAccountNumber {
12029 fn default() -> Self {
12030 Self {
12031 account_number: Default::default(),
12032 guid: Default::default(),
12033 institution_number: Default::default(),
12034 loan_guarantor: Default::default(),
12035 loan_reference_number: Default::default(),
12036 passed_validation: Default::default(),
12037 routing_number: Default::default(),
12038 sequence_number: Default::default(),
12039 transit_number: Default::default(),
12040 }
12041 }
12042 }
12043
12044 ///`ProcessorAccountNumberBody`
12045 ///
12046 /// <details><summary>JSON schema</summary>
12047 ///
12048 /// ```json
12049 ///{
12050 /// "type": "object",
12051 /// "properties": {
12052 /// "account_numbers": {
12053 /// "items": {
12054 /// "allOf": [
12055 /// {
12056 /// "$ref": "#/components/schemas/MemberElements"
12057 /// },
12058 /// {
12059 /// "$ref": "#/components/schemas/ProcessorAccountNumber"
12060 /// }
12061 /// ]
12062 /// }
12063 /// }
12064 /// }
12065 ///}
12066 /// ```
12067 /// </details>
12068 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
12069 pub struct ProcessorAccountNumberBody {
12070 #[serde(default, skip_serializing_if = "::std::vec::Vec::is_empty")]
12071 pub account_numbers: ::std::vec::Vec<ProcessorAccountNumberBodyAccountNumbersItem>,
12072 }
12073
12074 impl ::std::convert::From<&ProcessorAccountNumberBody> for ProcessorAccountNumberBody {
12075 fn from(value: &ProcessorAccountNumberBody) -> Self {
12076 value.clone()
12077 }
12078 }
12079
12080 impl ::std::default::Default for ProcessorAccountNumberBody {
12081 fn default() -> Self {
12082 Self {
12083 account_numbers: Default::default(),
12084 }
12085 }
12086 }
12087
12088 ///`ProcessorAccountNumberBodyAccountNumbersItem`
12089 ///
12090 /// <details><summary>JSON schema</summary>
12091 ///
12092 /// ```json
12093 ///{
12094 /// "allOf": [
12095 /// {
12096 /// "$ref": "#/components/schemas/MemberElements"
12097 /// },
12098 /// {
12099 /// "$ref": "#/components/schemas/ProcessorAccountNumber"
12100 /// }
12101 /// ]
12102 ///}
12103 /// ```
12104 /// </details>
12105 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
12106 pub struct ProcessorAccountNumberBodyAccountNumbersItem {
12107 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
12108 pub account_guid: ::std::option::Option<::std::string::String>,
12109 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
12110 pub account_number: ::std::option::Option<i64>,
12111 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
12112 pub guid: ::std::option::Option<::std::string::String>,
12113 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
12114 pub institution_number: ::std::option::Option<::serde_json::Value>,
12115 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
12116 pub loan_guarantor: ::std::option::Option<::serde_json::Value>,
12117 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
12118 pub loan_reference_number: ::std::option::Option<::serde_json::Value>,
12119 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
12120 pub member_guid: ::std::option::Option<::std::string::String>,
12121 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
12122 pub passed_validation: ::std::option::Option<::serde_json::Value>,
12123 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
12124 pub routing_number: ::std::option::Option<i64>,
12125 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
12126 pub sequence_number: ::std::option::Option<::serde_json::Value>,
12127 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
12128 pub transit_number: ::std::option::Option<::serde_json::Value>,
12129 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
12130 pub user_guid: ::std::option::Option<::std::string::String>,
12131 }
12132
12133 impl ::std::convert::From<&ProcessorAccountNumberBodyAccountNumbersItem>
12134 for ProcessorAccountNumberBodyAccountNumbersItem
12135 {
12136 fn from(value: &ProcessorAccountNumberBodyAccountNumbersItem) -> Self {
12137 value.clone()
12138 }
12139 }
12140
12141 impl ::std::default::Default for ProcessorAccountNumberBodyAccountNumbersItem {
12142 fn default() -> Self {
12143 Self {
12144 account_guid: Default::default(),
12145 account_number: Default::default(),
12146 guid: Default::default(),
12147 institution_number: Default::default(),
12148 loan_guarantor: Default::default(),
12149 loan_reference_number: Default::default(),
12150 member_guid: Default::default(),
12151 passed_validation: Default::default(),
12152 routing_number: Default::default(),
12153 sequence_number: Default::default(),
12154 transit_number: Default::default(),
12155 user_guid: Default::default(),
12156 }
12157 }
12158 }
12159
12160 ///`ProcessorOwner`
12161 ///
12162 /// <details><summary>JSON schema</summary>
12163 ///
12164 /// ```json
12165 ///{
12166 /// "properties": {
12167 /// "address": {
12168 /// "examples": [
12169 /// "3541 Adrian Street"
12170 /// ]
12171 /// },
12172 /// "city": {
12173 /// "examples": [
12174 /// "North Kishaberg"
12175 /// ]
12176 /// },
12177 /// "country": {},
12178 /// "email": {
12179 /// "examples": [
12180 /// "janita.pollich823@beerpowlowski.ca"
12181 /// ]
12182 /// },
12183 /// "guid": {
12184 /// "examples": [
12185 /// "ACO-a06b74ec-6a58-4c0b-b437-8de5e03194ac"
12186 /// ]
12187 /// },
12188 /// "owner_name": {
12189 /// "examples": [
12190 /// "Janita Pollich"
12191 /// ]
12192 /// },
12193 /// "phone": {
12194 /// "examples": [
12195 /// "676-932-5861"
12196 /// ]
12197 /// },
12198 /// "postal_code": {
12199 /// "examples": [
12200 /// "45054-7764"
12201 /// ]
12202 /// },
12203 /// "state": {
12204 /// "examples": [
12205 /// "Maine"
12206 /// ]
12207 /// }
12208 /// }
12209 ///}
12210 /// ```
12211 /// </details>
12212 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
12213 pub struct ProcessorOwner {
12214 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
12215 pub address: ::std::option::Option<::serde_json::Value>,
12216 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
12217 pub city: ::std::option::Option<::serde_json::Value>,
12218 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
12219 pub country: ::std::option::Option<::serde_json::Value>,
12220 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
12221 pub email: ::std::option::Option<::serde_json::Value>,
12222 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
12223 pub guid: ::std::option::Option<::serde_json::Value>,
12224 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
12225 pub owner_name: ::std::option::Option<::serde_json::Value>,
12226 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
12227 pub phone: ::std::option::Option<::serde_json::Value>,
12228 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
12229 pub postal_code: ::std::option::Option<::serde_json::Value>,
12230 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
12231 pub state: ::std::option::Option<::serde_json::Value>,
12232 }
12233
12234 impl ::std::convert::From<&ProcessorOwner> for ProcessorOwner {
12235 fn from(value: &ProcessorOwner) -> Self {
12236 value.clone()
12237 }
12238 }
12239
12240 impl ::std::default::Default for ProcessorOwner {
12241 fn default() -> Self {
12242 Self {
12243 address: Default::default(),
12244 city: Default::default(),
12245 country: Default::default(),
12246 email: Default::default(),
12247 guid: Default::default(),
12248 owner_name: Default::default(),
12249 phone: Default::default(),
12250 postal_code: Default::default(),
12251 state: Default::default(),
12252 }
12253 }
12254 }
12255
12256 ///`ProcessorOwnerBody`
12257 ///
12258 /// <details><summary>JSON schema</summary>
12259 ///
12260 /// ```json
12261 ///{
12262 /// "type": "object",
12263 /// "properties": {
12264 /// "account_owners": {
12265 /// "items": {
12266 /// "allOf": [
12267 /// {
12268 /// "$ref": "#/components/schemas/MemberElements"
12269 /// },
12270 /// {
12271 /// "$ref": "#/components/schemas/ProcessorOwner"
12272 /// }
12273 /// ]
12274 /// }
12275 /// },
12276 /// "pagination": {
12277 /// "$ref": "#/components/schemas/PaginationResponse"
12278 /// }
12279 /// }
12280 ///}
12281 /// ```
12282 /// </details>
12283 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
12284 pub struct ProcessorOwnerBody {
12285 #[serde(default, skip_serializing_if = "::std::vec::Vec::is_empty")]
12286 pub account_owners: ::std::vec::Vec<ProcessorOwnerBodyAccountOwnersItem>,
12287 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
12288 pub pagination: ::std::option::Option<PaginationResponse>,
12289 }
12290
12291 impl ::std::convert::From<&ProcessorOwnerBody> for ProcessorOwnerBody {
12292 fn from(value: &ProcessorOwnerBody) -> Self {
12293 value.clone()
12294 }
12295 }
12296
12297 impl ::std::default::Default for ProcessorOwnerBody {
12298 fn default() -> Self {
12299 Self {
12300 account_owners: Default::default(),
12301 pagination: Default::default(),
12302 }
12303 }
12304 }
12305
12306 ///`ProcessorOwnerBodyAccountOwnersItem`
12307 ///
12308 /// <details><summary>JSON schema</summary>
12309 ///
12310 /// ```json
12311 ///{
12312 /// "allOf": [
12313 /// {
12314 /// "$ref": "#/components/schemas/MemberElements"
12315 /// },
12316 /// {
12317 /// "$ref": "#/components/schemas/ProcessorOwner"
12318 /// }
12319 /// ]
12320 ///}
12321 /// ```
12322 /// </details>
12323 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
12324 pub struct ProcessorOwnerBodyAccountOwnersItem {
12325 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
12326 pub account_guid: ::std::option::Option<::std::string::String>,
12327 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
12328 pub address: ::std::option::Option<::serde_json::Value>,
12329 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
12330 pub city: ::std::option::Option<::serde_json::Value>,
12331 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
12332 pub country: ::std::option::Option<::serde_json::Value>,
12333 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
12334 pub email: ::std::option::Option<::serde_json::Value>,
12335 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
12336 pub guid: ::std::option::Option<::serde_json::Value>,
12337 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
12338 pub member_guid: ::std::option::Option<::std::string::String>,
12339 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
12340 pub owner_name: ::std::option::Option<::serde_json::Value>,
12341 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
12342 pub phone: ::std::option::Option<::serde_json::Value>,
12343 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
12344 pub postal_code: ::std::option::Option<::serde_json::Value>,
12345 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
12346 pub state: ::std::option::Option<::serde_json::Value>,
12347 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
12348 pub user_guid: ::std::option::Option<::std::string::String>,
12349 }
12350
12351 impl ::std::convert::From<&ProcessorOwnerBodyAccountOwnersItem>
12352 for ProcessorOwnerBodyAccountOwnersItem
12353 {
12354 fn from(value: &ProcessorOwnerBodyAccountOwnersItem) -> Self {
12355 value.clone()
12356 }
12357 }
12358
12359 impl ::std::default::Default for ProcessorOwnerBodyAccountOwnersItem {
12360 fn default() -> Self {
12361 Self {
12362 account_guid: Default::default(),
12363 address: Default::default(),
12364 city: Default::default(),
12365 country: Default::default(),
12366 email: Default::default(),
12367 guid: Default::default(),
12368 member_guid: Default::default(),
12369 owner_name: Default::default(),
12370 phone: Default::default(),
12371 postal_code: Default::default(),
12372 state: Default::default(),
12373 user_guid: Default::default(),
12374 }
12375 }
12376 }
12377
12378 ///`RepeatingTransactionResponse`
12379 ///
12380 /// <details><summary>JSON schema</summary>
12381 ///
12382 /// ```json
12383 ///{
12384 /// "properties": {
12385 /// "account_guid": {
12386 /// "examples": [
12387 /// "ACT-0af29528-bb91-447f-b5de-85c1c42593e5"
12388 /// ],
12389 /// "type": [
12390 /// "string",
12391 /// "null"
12392 /// ]
12393 /// },
12394 /// "amount": {
12395 /// "examples": [
12396 /// 107.4
12397 /// ],
12398 /// "type": "number"
12399 /// },
12400 /// "description": {
12401 /// "examples": [
12402 /// "Dominion Energy"
12403 /// ],
12404 /// "type": "string"
12405 /// },
12406 /// "guid": {
12407 /// "examples": [
12408 /// "RPT-a2264e1a-d2e6-41d9-88d2-2cfdf1143959"
12409 /// ],
12410 /// "type": "string"
12411 /// },
12412 /// "last_posted_date": {
12413 /// "examples": [
12414 /// "2024-12-09"
12415 /// ],
12416 /// "type": "string"
12417 /// },
12418 /// "member_guid": {
12419 /// "examples": [
12420 /// "MBR-78b14c5f-7297-4fb5-a966-65ac45f74d83"
12421 /// ],
12422 /// "type": "string"
12423 /// },
12424 /// "merchant_guid": {
12425 /// "examples": [
12426 /// "MCH-1b5d7e4d-fa29-95d1-fd0f-540b6f17d986"
12427 /// ],
12428 /// "type": "string"
12429 /// },
12430 /// "predicted_occurs_on": {
12431 /// "examples": [
12432 /// "2025-01-09"
12433 /// ],
12434 /// "type": "string"
12435 /// },
12436 /// "recurrence_type": {
12437 /// "examples": [
12438 /// "EVERY_MONTH"
12439 /// ],
12440 /// "type": "string"
12441 /// },
12442 /// "repeating_transaction_type": {
12443 /// "type": "string",
12444 /// "enum": [
12445 /// "BILL",
12446 /// "SUBSCRIPTION",
12447 /// "INCOME",
12448 /// "UNKNOWN"
12449 /// ]
12450 /// },
12451 /// "transaction_type": {
12452 /// "type": "string",
12453 /// "enum": [
12454 /// "DEBIT",
12455 /// "CREDIT"
12456 /// ]
12457 /// },
12458 /// "user_guid": {
12459 /// "type": "string"
12460 /// }
12461 /// }
12462 ///}
12463 /// ```
12464 /// </details>
12465 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
12466 pub struct RepeatingTransactionResponse {
12467 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
12468 pub account_guid: ::std::option::Option<::std::string::String>,
12469 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
12470 pub amount: ::std::option::Option<f64>,
12471 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
12472 pub description: ::std::option::Option<::std::string::String>,
12473 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
12474 pub guid: ::std::option::Option<::std::string::String>,
12475 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
12476 pub last_posted_date: ::std::option::Option<::std::string::String>,
12477 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
12478 pub member_guid: ::std::option::Option<::std::string::String>,
12479 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
12480 pub merchant_guid: ::std::option::Option<::std::string::String>,
12481 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
12482 pub predicted_occurs_on: ::std::option::Option<::std::string::String>,
12483 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
12484 pub recurrence_type: ::std::option::Option<::std::string::String>,
12485 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
12486 pub repeating_transaction_type:
12487 ::std::option::Option<RepeatingTransactionResponseRepeatingTransactionType>,
12488 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
12489 pub transaction_type: ::std::option::Option<RepeatingTransactionResponseTransactionType>,
12490 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
12491 pub user_guid: ::std::option::Option<::std::string::String>,
12492 }
12493
12494 impl ::std::convert::From<&RepeatingTransactionResponse> for RepeatingTransactionResponse {
12495 fn from(value: &RepeatingTransactionResponse) -> Self {
12496 value.clone()
12497 }
12498 }
12499
12500 impl ::std::default::Default for RepeatingTransactionResponse {
12501 fn default() -> Self {
12502 Self {
12503 account_guid: Default::default(),
12504 amount: Default::default(),
12505 description: Default::default(),
12506 guid: Default::default(),
12507 last_posted_date: Default::default(),
12508 member_guid: Default::default(),
12509 merchant_guid: Default::default(),
12510 predicted_occurs_on: Default::default(),
12511 recurrence_type: Default::default(),
12512 repeating_transaction_type: Default::default(),
12513 transaction_type: Default::default(),
12514 user_guid: Default::default(),
12515 }
12516 }
12517 }
12518
12519 ///`RepeatingTransactionResponseRepeatingTransactionType`
12520 ///
12521 /// <details><summary>JSON schema</summary>
12522 ///
12523 /// ```json
12524 ///{
12525 /// "type": "string",
12526 /// "enum": [
12527 /// "BILL",
12528 /// "SUBSCRIPTION",
12529 /// "INCOME",
12530 /// "UNKNOWN"
12531 /// ]
12532 ///}
12533 /// ```
12534 /// </details>
12535 #[derive(
12536 :: serde :: Deserialize,
12537 :: serde :: Serialize,
12538 Clone,
12539 Copy,
12540 Debug,
12541 Eq,
12542 Hash,
12543 Ord,
12544 PartialEq,
12545 PartialOrd,
12546 )]
12547 pub enum RepeatingTransactionResponseRepeatingTransactionType {
12548 #[serde(rename = "BILL")]
12549 Bill,
12550 #[serde(rename = "SUBSCRIPTION")]
12551 Subscription,
12552 #[serde(rename = "INCOME")]
12553 Income,
12554 #[serde(rename = "UNKNOWN")]
12555 Unknown,
12556 }
12557
12558 impl ::std::convert::From<&Self> for RepeatingTransactionResponseRepeatingTransactionType {
12559 fn from(value: &RepeatingTransactionResponseRepeatingTransactionType) -> Self {
12560 value.clone()
12561 }
12562 }
12563
12564 impl ::std::fmt::Display for RepeatingTransactionResponseRepeatingTransactionType {
12565 fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
12566 match *self {
12567 Self::Bill => f.write_str("BILL"),
12568 Self::Subscription => f.write_str("SUBSCRIPTION"),
12569 Self::Income => f.write_str("INCOME"),
12570 Self::Unknown => f.write_str("UNKNOWN"),
12571 }
12572 }
12573 }
12574
12575 impl ::std::str::FromStr for RepeatingTransactionResponseRepeatingTransactionType {
12576 type Err = self::error::ConversionError;
12577 fn from_str(value: &str) -> ::std::result::Result<Self, self::error::ConversionError> {
12578 match value {
12579 "BILL" => Ok(Self::Bill),
12580 "SUBSCRIPTION" => Ok(Self::Subscription),
12581 "INCOME" => Ok(Self::Income),
12582 "UNKNOWN" => Ok(Self::Unknown),
12583 _ => Err("invalid value".into()),
12584 }
12585 }
12586 }
12587
12588 impl ::std::convert::TryFrom<&str> for RepeatingTransactionResponseRepeatingTransactionType {
12589 type Error = self::error::ConversionError;
12590 fn try_from(value: &str) -> ::std::result::Result<Self, self::error::ConversionError> {
12591 value.parse()
12592 }
12593 }
12594
12595 impl ::std::convert::TryFrom<&::std::string::String>
12596 for RepeatingTransactionResponseRepeatingTransactionType
12597 {
12598 type Error = self::error::ConversionError;
12599 fn try_from(
12600 value: &::std::string::String,
12601 ) -> ::std::result::Result<Self, self::error::ConversionError> {
12602 value.parse()
12603 }
12604 }
12605
12606 impl ::std::convert::TryFrom<::std::string::String>
12607 for RepeatingTransactionResponseRepeatingTransactionType
12608 {
12609 type Error = self::error::ConversionError;
12610 fn try_from(
12611 value: ::std::string::String,
12612 ) -> ::std::result::Result<Self, self::error::ConversionError> {
12613 value.parse()
12614 }
12615 }
12616
12617 ///`RepeatingTransactionResponseTransactionType`
12618 ///
12619 /// <details><summary>JSON schema</summary>
12620 ///
12621 /// ```json
12622 ///{
12623 /// "type": "string",
12624 /// "enum": [
12625 /// "DEBIT",
12626 /// "CREDIT"
12627 /// ]
12628 ///}
12629 /// ```
12630 /// </details>
12631 #[derive(
12632 :: serde :: Deserialize,
12633 :: serde :: Serialize,
12634 Clone,
12635 Copy,
12636 Debug,
12637 Eq,
12638 Hash,
12639 Ord,
12640 PartialEq,
12641 PartialOrd,
12642 )]
12643 pub enum RepeatingTransactionResponseTransactionType {
12644 #[serde(rename = "DEBIT")]
12645 Debit,
12646 #[serde(rename = "CREDIT")]
12647 Credit,
12648 }
12649
12650 impl ::std::convert::From<&Self> for RepeatingTransactionResponseTransactionType {
12651 fn from(value: &RepeatingTransactionResponseTransactionType) -> Self {
12652 value.clone()
12653 }
12654 }
12655
12656 impl ::std::fmt::Display for RepeatingTransactionResponseTransactionType {
12657 fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
12658 match *self {
12659 Self::Debit => f.write_str("DEBIT"),
12660 Self::Credit => f.write_str("CREDIT"),
12661 }
12662 }
12663 }
12664
12665 impl ::std::str::FromStr for RepeatingTransactionResponseTransactionType {
12666 type Err = self::error::ConversionError;
12667 fn from_str(value: &str) -> ::std::result::Result<Self, self::error::ConversionError> {
12668 match value {
12669 "DEBIT" => Ok(Self::Debit),
12670 "CREDIT" => Ok(Self::Credit),
12671 _ => Err("invalid value".into()),
12672 }
12673 }
12674 }
12675
12676 impl ::std::convert::TryFrom<&str> for RepeatingTransactionResponseTransactionType {
12677 type Error = self::error::ConversionError;
12678 fn try_from(value: &str) -> ::std::result::Result<Self, self::error::ConversionError> {
12679 value.parse()
12680 }
12681 }
12682
12683 impl ::std::convert::TryFrom<&::std::string::String>
12684 for RepeatingTransactionResponseTransactionType
12685 {
12686 type Error = self::error::ConversionError;
12687 fn try_from(
12688 value: &::std::string::String,
12689 ) -> ::std::result::Result<Self, self::error::ConversionError> {
12690 value.parse()
12691 }
12692 }
12693
12694 impl ::std::convert::TryFrom<::std::string::String>
12695 for RepeatingTransactionResponseTransactionType
12696 {
12697 type Error = self::error::ConversionError;
12698 fn try_from(
12699 value: ::std::string::String,
12700 ) -> ::std::result::Result<Self, self::error::ConversionError> {
12701 value.parse()
12702 }
12703 }
12704
12705 ///`RepeatingTransactionsResponseBody`
12706 ///
12707 /// <details><summary>JSON schema</summary>
12708 ///
12709 /// ```json
12710 ///{
12711 /// "type": "object",
12712 /// "properties": {
12713 /// "repeating_transactions": {
12714 /// "type": "array",
12715 /// "items": {
12716 /// "$ref": "#/components/schemas/RepeatingTransactionResponse"
12717 /// }
12718 /// }
12719 /// }
12720 ///}
12721 /// ```
12722 /// </details>
12723 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
12724 pub struct RepeatingTransactionsResponseBody {
12725 #[serde(default, skip_serializing_if = "::std::vec::Vec::is_empty")]
12726 pub repeating_transactions: ::std::vec::Vec<RepeatingTransactionResponse>,
12727 }
12728
12729 impl ::std::convert::From<&RepeatingTransactionsResponseBody>
12730 for RepeatingTransactionsResponseBody
12731 {
12732 fn from(value: &RepeatingTransactionsResponseBody) -> Self {
12733 value.clone()
12734 }
12735 }
12736
12737 impl ::std::default::Default for RepeatingTransactionsResponseBody {
12738 fn default() -> Self {
12739 Self {
12740 repeating_transactions: Default::default(),
12741 }
12742 }
12743 }
12744
12745 ///`RepositionRequest`
12746 ///
12747 /// <details><summary>JSON schema</summary>
12748 ///
12749 /// ```json
12750 ///{
12751 /// "required": [
12752 /// "guid",
12753 /// "position"
12754 /// ],
12755 /// "properties": {
12756 /// "guid": {
12757 /// "description": "The unique identifier for the goal. Defined by
12758 /// MX.",
12759 /// "examples": [
12760 /// "GOL-97665947-235c-b213-ca25-8cf0174774f5"
12761 /// ],
12762 /// "type": "string"
12763 /// },
12764 /// "position": {
12765 /// "description": "The priority of the goal in relation to multiple
12766 /// goals.",
12767 /// "examples": [
12768 /// 1
12769 /// ],
12770 /// "type": "integer"
12771 /// }
12772 /// }
12773 ///}
12774 /// ```
12775 /// </details>
12776 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
12777 pub struct RepositionRequest {
12778 ///The unique identifier for the goal. Defined by MX.
12779 pub guid: ::std::string::String,
12780 ///The priority of the goal in relation to multiple goals.
12781 pub position: i64,
12782 }
12783
12784 impl ::std::convert::From<&RepositionRequest> for RepositionRequest {
12785 fn from(value: &RepositionRequest) -> Self {
12786 value.clone()
12787 }
12788 }
12789
12790 ///`RepositionRequestBody`
12791 ///
12792 /// <details><summary>JSON schema</summary>
12793 ///
12794 /// ```json
12795 ///{
12796 /// "type": "object",
12797 /// "properties": {
12798 /// "goals": {
12799 /// "type": "array",
12800 /// "items": {
12801 /// "$ref": "#/components/schemas/RepositionRequest"
12802 /// }
12803 /// }
12804 /// }
12805 ///}
12806 /// ```
12807 /// </details>
12808 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
12809 pub struct RepositionRequestBody {
12810 #[serde(default, skip_serializing_if = "::std::vec::Vec::is_empty")]
12811 pub goals: ::std::vec::Vec<RepositionRequest>,
12812 }
12813
12814 impl ::std::convert::From<&RepositionRequestBody> for RepositionRequestBody {
12815 fn from(value: &RepositionRequestBody) -> Self {
12816 value.clone()
12817 }
12818 }
12819
12820 impl ::std::default::Default for RepositionRequestBody {
12821 fn default() -> Self {
12822 Self {
12823 goals: Default::default(),
12824 }
12825 }
12826 }
12827
12828 ///`RepositionResponseBody`
12829 ///
12830 /// <details><summary>JSON schema</summary>
12831 ///
12832 /// ```json
12833 ///{
12834 /// "type": "object",
12835 /// "properties": {
12836 /// "goals": {
12837 /// "type": "array",
12838 /// "items": {
12839 /// "$ref": "#/components/schemas/GoalsResponse"
12840 /// }
12841 /// }
12842 /// }
12843 ///}
12844 /// ```
12845 /// </details>
12846 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
12847 pub struct RepositionResponseBody {
12848 #[serde(default, skip_serializing_if = "::std::vec::Vec::is_empty")]
12849 pub goals: ::std::vec::Vec<GoalsResponse>,
12850 }
12851
12852 impl ::std::convert::From<&RepositionResponseBody> for RepositionResponseBody {
12853 fn from(value: &RepositionResponseBody) -> Self {
12854 value.clone()
12855 }
12856 }
12857
12858 impl ::std::default::Default for RepositionResponseBody {
12859 fn default() -> Self {
12860 Self {
12861 goals: Default::default(),
12862 }
12863 }
12864 }
12865
12866 ///`RewardElements`
12867 ///
12868 /// <details><summary>JSON schema</summary>
12869 ///
12870 /// ```json
12871 ///{
12872 /// "properties": {
12873 /// "balance": {
12874 /// "examples": [
12875 /// 102
12876 /// ],
12877 /// "type": "integer"
12878 /// },
12879 /// "balance_type": {
12880 /// "examples": [
12881 /// "EXPIRING_BALANCE"
12882 /// ],
12883 /// "type": "string"
12884 /// },
12885 /// "created_at": {
12886 /// "examples": [
12887 /// "2020-01-28T21:09:01+0000"
12888 /// ],
12889 /// "type": "string"
12890 /// },
12891 /// "description": {
12892 /// "examples": [
12893 /// "A description of the reward."
12894 /// ],
12895 /// "type": "string"
12896 /// },
12897 /// "expires_on": {
12898 /// "examples": [
12899 /// "2020-02-28"
12900 /// ],
12901 /// "type": "string"
12902 /// },
12903 /// "guid": {
12904 /// "examples": [
12905 /// "RWD-1234"
12906 /// ],
12907 /// "type": "string"
12908 /// },
12909 /// "unit_type": {
12910 /// "examples": [
12911 /// "POINTS"
12912 /// ],
12913 /// "type": "string"
12914 /// },
12915 /// "updated_at": {
12916 /// "examples": [
12917 /// "2023-06-01T19:18:06Z"
12918 /// ],
12919 /// "type": "string"
12920 /// }
12921 /// }
12922 ///}
12923 /// ```
12924 /// </details>
12925 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
12926 pub struct RewardElements {
12927 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
12928 pub balance: ::std::option::Option<i64>,
12929 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
12930 pub balance_type: ::std::option::Option<::std::string::String>,
12931 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
12932 pub created_at: ::std::option::Option<::std::string::String>,
12933 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
12934 pub description: ::std::option::Option<::std::string::String>,
12935 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
12936 pub expires_on: ::std::option::Option<::std::string::String>,
12937 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
12938 pub guid: ::std::option::Option<::std::string::String>,
12939 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
12940 pub unit_type: ::std::option::Option<::std::string::String>,
12941 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
12942 pub updated_at: ::std::option::Option<::std::string::String>,
12943 }
12944
12945 impl ::std::convert::From<&RewardElements> for RewardElements {
12946 fn from(value: &RewardElements) -> Self {
12947 value.clone()
12948 }
12949 }
12950
12951 impl ::std::default::Default for RewardElements {
12952 fn default() -> Self {
12953 Self {
12954 balance: Default::default(),
12955 balance_type: Default::default(),
12956 created_at: Default::default(),
12957 description: Default::default(),
12958 expires_on: Default::default(),
12959 guid: Default::default(),
12960 unit_type: Default::default(),
12961 updated_at: Default::default(),
12962 }
12963 }
12964 }
12965
12966 ///`RewardResponseBody`
12967 ///
12968 /// <details><summary>JSON schema</summary>
12969 ///
12970 /// ```json
12971 ///{
12972 /// "type": "object",
12973 /// "properties": {
12974 /// "reward": {
12975 /// "allOf": [
12976 /// {
12977 /// "$ref": "#/components/schemas/MemberElements"
12978 /// },
12979 /// {
12980 /// "$ref": "#/components/schemas/RewardElements"
12981 /// }
12982 /// ]
12983 /// }
12984 /// }
12985 ///}
12986 /// ```
12987 /// </details>
12988 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
12989 pub struct RewardResponseBody {
12990 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
12991 pub reward: ::std::option::Option<RewardResponseBodyReward>,
12992 }
12993
12994 impl ::std::convert::From<&RewardResponseBody> for RewardResponseBody {
12995 fn from(value: &RewardResponseBody) -> Self {
12996 value.clone()
12997 }
12998 }
12999
13000 impl ::std::default::Default for RewardResponseBody {
13001 fn default() -> Self {
13002 Self {
13003 reward: Default::default(),
13004 }
13005 }
13006 }
13007
13008 ///`RewardResponseBodyReward`
13009 ///
13010 /// <details><summary>JSON schema</summary>
13011 ///
13012 /// ```json
13013 ///{
13014 /// "allOf": [
13015 /// {
13016 /// "$ref": "#/components/schemas/MemberElements"
13017 /// },
13018 /// {
13019 /// "$ref": "#/components/schemas/RewardElements"
13020 /// }
13021 /// ]
13022 ///}
13023 /// ```
13024 /// </details>
13025 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
13026 pub struct RewardResponseBodyReward {
13027 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13028 pub account_guid: ::std::option::Option<::std::string::String>,
13029 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13030 pub balance: ::std::option::Option<i64>,
13031 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13032 pub balance_type: ::std::option::Option<::std::string::String>,
13033 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13034 pub created_at: ::std::option::Option<::std::string::String>,
13035 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13036 pub description: ::std::option::Option<::std::string::String>,
13037 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13038 pub expires_on: ::std::option::Option<::std::string::String>,
13039 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13040 pub guid: ::std::option::Option<::std::string::String>,
13041 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13042 pub member_guid: ::std::option::Option<::std::string::String>,
13043 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13044 pub unit_type: ::std::option::Option<::std::string::String>,
13045 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13046 pub updated_at: ::std::option::Option<::std::string::String>,
13047 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13048 pub user_guid: ::std::option::Option<::std::string::String>,
13049 }
13050
13051 impl ::std::convert::From<&RewardResponseBodyReward> for RewardResponseBodyReward {
13052 fn from(value: &RewardResponseBodyReward) -> Self {
13053 value.clone()
13054 }
13055 }
13056
13057 impl ::std::default::Default for RewardResponseBodyReward {
13058 fn default() -> Self {
13059 Self {
13060 account_guid: Default::default(),
13061 balance: Default::default(),
13062 balance_type: Default::default(),
13063 created_at: Default::default(),
13064 description: Default::default(),
13065 expires_on: Default::default(),
13066 guid: Default::default(),
13067 member_guid: Default::default(),
13068 unit_type: Default::default(),
13069 updated_at: Default::default(),
13070 user_guid: Default::default(),
13071 }
13072 }
13073 }
13074
13075 ///`RewardsResponseBody`
13076 ///
13077 /// <details><summary>JSON schema</summary>
13078 ///
13079 /// ```json
13080 ///{
13081 /// "type": "object",
13082 /// "properties": {
13083 /// "pagination": {
13084 /// "$ref": "#/components/schemas/PaginationResponse"
13085 /// },
13086 /// "rewards": {
13087 /// "type": "array",
13088 /// "items": {
13089 /// "allOf": [
13090 /// {
13091 /// "$ref": "#/components/schemas/MemberElements"
13092 /// },
13093 /// {
13094 /// "$ref": "#/components/schemas/RewardElements"
13095 /// }
13096 /// ]
13097 /// }
13098 /// }
13099 /// }
13100 ///}
13101 /// ```
13102 /// </details>
13103 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
13104 pub struct RewardsResponseBody {
13105 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13106 pub pagination: ::std::option::Option<PaginationResponse>,
13107 #[serde(default, skip_serializing_if = "::std::vec::Vec::is_empty")]
13108 pub rewards: ::std::vec::Vec<RewardsResponseBodyRewardsItem>,
13109 }
13110
13111 impl ::std::convert::From<&RewardsResponseBody> for RewardsResponseBody {
13112 fn from(value: &RewardsResponseBody) -> Self {
13113 value.clone()
13114 }
13115 }
13116
13117 impl ::std::default::Default for RewardsResponseBody {
13118 fn default() -> Self {
13119 Self {
13120 pagination: Default::default(),
13121 rewards: Default::default(),
13122 }
13123 }
13124 }
13125
13126 ///`RewardsResponseBodyRewardsItem`
13127 ///
13128 /// <details><summary>JSON schema</summary>
13129 ///
13130 /// ```json
13131 ///{
13132 /// "allOf": [
13133 /// {
13134 /// "$ref": "#/components/schemas/MemberElements"
13135 /// },
13136 /// {
13137 /// "$ref": "#/components/schemas/RewardElements"
13138 /// }
13139 /// ]
13140 ///}
13141 /// ```
13142 /// </details>
13143 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
13144 pub struct RewardsResponseBodyRewardsItem {
13145 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13146 pub account_guid: ::std::option::Option<::std::string::String>,
13147 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13148 pub balance: ::std::option::Option<i64>,
13149 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13150 pub balance_type: ::std::option::Option<::std::string::String>,
13151 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13152 pub created_at: ::std::option::Option<::std::string::String>,
13153 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13154 pub description: ::std::option::Option<::std::string::String>,
13155 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13156 pub expires_on: ::std::option::Option<::std::string::String>,
13157 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13158 pub guid: ::std::option::Option<::std::string::String>,
13159 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13160 pub member_guid: ::std::option::Option<::std::string::String>,
13161 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13162 pub unit_type: ::std::option::Option<::std::string::String>,
13163 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13164 pub updated_at: ::std::option::Option<::std::string::String>,
13165 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13166 pub user_guid: ::std::option::Option<::std::string::String>,
13167 }
13168
13169 impl ::std::convert::From<&RewardsResponseBodyRewardsItem> for RewardsResponseBodyRewardsItem {
13170 fn from(value: &RewardsResponseBodyRewardsItem) -> Self {
13171 value.clone()
13172 }
13173 }
13174
13175 impl ::std::default::Default for RewardsResponseBodyRewardsItem {
13176 fn default() -> Self {
13177 Self {
13178 account_guid: Default::default(),
13179 balance: Default::default(),
13180 balance_type: Default::default(),
13181 created_at: Default::default(),
13182 description: Default::default(),
13183 expires_on: Default::default(),
13184 guid: Default::default(),
13185 member_guid: Default::default(),
13186 unit_type: Default::default(),
13187 updated_at: Default::default(),
13188 user_guid: Default::default(),
13189 }
13190 }
13191 }
13192
13193 ///`ScheduledPaymentResponse`
13194 ///
13195 /// <details><summary>JSON schema</summary>
13196 ///
13197 /// ```json
13198 ///{
13199 /// "type": "object",
13200 /// "properties": {
13201 /// "amount": {
13202 /// "examples": [
13203 /// 13.54
13204 /// ],
13205 /// "type": "number"
13206 /// },
13207 /// "created_at": {
13208 /// "examples": [
13209 /// "2023-04-27T23:14:16Z"
13210 /// ],
13211 /// "type": "string"
13212 /// },
13213 /// "description": {
13214 /// "examples": [
13215 /// "Netflix"
13216 /// ],
13217 /// "type": "string"
13218 /// },
13219 /// "guid": {
13220 /// "examples": [
13221 /// "SPA-c76e4a85-b2c4-4335-82b7-8f8b8f28c35a"
13222 /// ],
13223 /// "type": "string"
13224 /// },
13225 /// "is_completed": {
13226 /// "examples": [
13227 /// false
13228 /// ],
13229 /// "type": "boolean"
13230 /// },
13231 /// "is_recurring": {
13232 /// "examples": [
13233 /// true
13234 /// ],
13235 /// "type": "boolean"
13236 /// },
13237 /// "merchant_guid": {
13238 /// "examples": [
13239 /// "MCH-b8a2624c-2176-59ec-c150-37854bc38aa8"
13240 /// ],
13241 /// "type": "string"
13242 /// },
13243 /// "occurs_on": {
13244 /// "examples": [
13245 /// "2022-01-15"
13246 /// ],
13247 /// "type": "string"
13248 /// },
13249 /// "recurrence_day": {
13250 /// "examples": [
13251 /// 15
13252 /// ],
13253 /// "type": "integer"
13254 /// },
13255 /// "recurrence_type": {
13256 /// "examples": [
13257 /// "EVERY_MONTH"
13258 /// ],
13259 /// "type": "string"
13260 /// },
13261 /// "transaction_type": {
13262 /// "examples": [
13263 /// "DEBIT"
13264 /// ],
13265 /// "type": "string"
13266 /// },
13267 /// "updated_at": {
13268 /// "examples": [
13269 /// "2023-04-27T23:14:16Z"
13270 /// ],
13271 /// "type": "string"
13272 /// },
13273 /// "user_guid": {
13274 /// "examples": [
13275 /// "USR-72086f59-6684-4adf-8f29-c4d32db43cd7"
13276 /// ],
13277 /// "type": "string"
13278 /// }
13279 /// }
13280 ///}
13281 /// ```
13282 /// </details>
13283 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
13284 pub struct ScheduledPaymentResponse {
13285 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13286 pub amount: ::std::option::Option<f64>,
13287 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13288 pub created_at: ::std::option::Option<::std::string::String>,
13289 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13290 pub description: ::std::option::Option<::std::string::String>,
13291 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13292 pub guid: ::std::option::Option<::std::string::String>,
13293 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13294 pub is_completed: ::std::option::Option<bool>,
13295 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13296 pub is_recurring: ::std::option::Option<bool>,
13297 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13298 pub merchant_guid: ::std::option::Option<::std::string::String>,
13299 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13300 pub occurs_on: ::std::option::Option<::std::string::String>,
13301 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13302 pub recurrence_day: ::std::option::Option<i64>,
13303 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13304 pub recurrence_type: ::std::option::Option<::std::string::String>,
13305 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13306 pub transaction_type: ::std::option::Option<::std::string::String>,
13307 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13308 pub updated_at: ::std::option::Option<::std::string::String>,
13309 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13310 pub user_guid: ::std::option::Option<::std::string::String>,
13311 }
13312
13313 impl ::std::convert::From<&ScheduledPaymentResponse> for ScheduledPaymentResponse {
13314 fn from(value: &ScheduledPaymentResponse) -> Self {
13315 value.clone()
13316 }
13317 }
13318
13319 impl ::std::default::Default for ScheduledPaymentResponse {
13320 fn default() -> Self {
13321 Self {
13322 amount: Default::default(),
13323 created_at: Default::default(),
13324 description: Default::default(),
13325 guid: Default::default(),
13326 is_completed: Default::default(),
13327 is_recurring: Default::default(),
13328 merchant_guid: Default::default(),
13329 occurs_on: Default::default(),
13330 recurrence_day: Default::default(),
13331 recurrence_type: Default::default(),
13332 transaction_type: Default::default(),
13333 updated_at: Default::default(),
13334 user_guid: Default::default(),
13335 }
13336 }
13337 }
13338
13339 ///`ScheduledPaymentsResponseBody`
13340 ///
13341 /// <details><summary>JSON schema</summary>
13342 ///
13343 /// ```json
13344 ///{
13345 /// "type": "object",
13346 /// "properties": {
13347 /// "pagination": {
13348 /// "$ref": "#/components/schemas/PaginationResponse"
13349 /// },
13350 /// "scheduled_payments": {
13351 /// "type": "array",
13352 /// "items": {
13353 /// "$ref": "#/components/schemas/ScheduledPaymentResponse"
13354 /// }
13355 /// }
13356 /// }
13357 ///}
13358 /// ```
13359 /// </details>
13360 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
13361 pub struct ScheduledPaymentsResponseBody {
13362 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13363 pub pagination: ::std::option::Option<PaginationResponse>,
13364 #[serde(default, skip_serializing_if = "::std::vec::Vec::is_empty")]
13365 pub scheduled_payments: ::std::vec::Vec<ScheduledPaymentResponse>,
13366 }
13367
13368 impl ::std::convert::From<&ScheduledPaymentsResponseBody> for ScheduledPaymentsResponseBody {
13369 fn from(value: &ScheduledPaymentsResponseBody) -> Self {
13370 value.clone()
13371 }
13372 }
13373
13374 impl ::std::default::Default for ScheduledPaymentsResponseBody {
13375 fn default() -> Self {
13376 Self {
13377 pagination: Default::default(),
13378 scheduled_payments: Default::default(),
13379 }
13380 }
13381 }
13382
13383 ///`SpendingPlanAccountResponse`
13384 ///
13385 /// <details><summary>JSON schema</summary>
13386 ///
13387 /// ```json
13388 ///{
13389 /// "type": "object",
13390 /// "properties": {
13391 /// "account_guid": {
13392 /// "examples": [
13393 /// "ACT-97d3948f-ebe7-434a-9bd0-20b29d67c9d4"
13394 /// ],
13395 /// "type": "string"
13396 /// },
13397 /// "client_guid": {
13398 /// "examples": [
13399 /// "CLT-024284fc-a6a7-42ee-b363-dab9343e3f72"
13400 /// ],
13401 /// "type": "string"
13402 /// },
13403 /// "created_at": {
13404 /// "examples": [
13405 /// "2023-04-27T23:14:16Z"
13406 /// ],
13407 /// "type": "string"
13408 /// },
13409 /// "guid": {
13410 /// "examples": [
13411 /// "SPA-c76e4a85-b2c4-4335-82b7-8f8b8f28c35a"
13412 /// ],
13413 /// "type": "string"
13414 /// },
13415 /// "spending_plan_guid": {
13416 /// "examples": [
13417 /// "SPL-dbfe201d-c341-4bff-93c0-62a918d0b600"
13418 /// ],
13419 /// "type": "string"
13420 /// },
13421 /// "updated_at": {
13422 /// "examples": [
13423 /// "2023-04-27T23:14:16Z"
13424 /// ],
13425 /// "type": "string"
13426 /// },
13427 /// "user_guid": {
13428 /// "examples": [
13429 /// "USR-72086f59-6684-4adf-8f29-c4d32db43cd7"
13430 /// ],
13431 /// "type": "string"
13432 /// }
13433 /// }
13434 ///}
13435 /// ```
13436 /// </details>
13437 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
13438 pub struct SpendingPlanAccountResponse {
13439 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13440 pub account_guid: ::std::option::Option<::std::string::String>,
13441 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13442 pub client_guid: ::std::option::Option<::std::string::String>,
13443 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13444 pub created_at: ::std::option::Option<::std::string::String>,
13445 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13446 pub guid: ::std::option::Option<::std::string::String>,
13447 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13448 pub spending_plan_guid: ::std::option::Option<::std::string::String>,
13449 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13450 pub updated_at: ::std::option::Option<::std::string::String>,
13451 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13452 pub user_guid: ::std::option::Option<::std::string::String>,
13453 }
13454
13455 impl ::std::convert::From<&SpendingPlanAccountResponse> for SpendingPlanAccountResponse {
13456 fn from(value: &SpendingPlanAccountResponse) -> Self {
13457 value.clone()
13458 }
13459 }
13460
13461 impl ::std::default::Default for SpendingPlanAccountResponse {
13462 fn default() -> Self {
13463 Self {
13464 account_guid: Default::default(),
13465 client_guid: Default::default(),
13466 created_at: Default::default(),
13467 guid: Default::default(),
13468 spending_plan_guid: Default::default(),
13469 updated_at: Default::default(),
13470 user_guid: Default::default(),
13471 }
13472 }
13473 }
13474
13475 ///`SpendingPlanAccountsResponse`
13476 ///
13477 /// <details><summary>JSON schema</summary>
13478 ///
13479 /// ```json
13480 ///{
13481 /// "type": "object",
13482 /// "properties": {
13483 /// "pagination": {
13484 /// "$ref": "#/components/schemas/PaginationResponse"
13485 /// },
13486 /// "spending_plan_accounts": {
13487 /// "type": "array",
13488 /// "items": {
13489 /// "$ref": "#/components/schemas/SpendingPlanAccountResponse"
13490 /// }
13491 /// }
13492 /// }
13493 ///}
13494 /// ```
13495 /// </details>
13496 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
13497 pub struct SpendingPlanAccountsResponse {
13498 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13499 pub pagination: ::std::option::Option<PaginationResponse>,
13500 #[serde(default, skip_serializing_if = "::std::vec::Vec::is_empty")]
13501 pub spending_plan_accounts: ::std::vec::Vec<SpendingPlanAccountResponse>,
13502 }
13503
13504 impl ::std::convert::From<&SpendingPlanAccountsResponse> for SpendingPlanAccountsResponse {
13505 fn from(value: &SpendingPlanAccountsResponse) -> Self {
13506 value.clone()
13507 }
13508 }
13509
13510 impl ::std::default::Default for SpendingPlanAccountsResponse {
13511 fn default() -> Self {
13512 Self {
13513 pagination: Default::default(),
13514 spending_plan_accounts: Default::default(),
13515 }
13516 }
13517 }
13518
13519 ///`SpendingPlanIterationItemCreateRequestBody`
13520 ///
13521 /// <details><summary>JSON schema</summary>
13522 ///
13523 /// ```json
13524 ///{
13525 /// "type": "object",
13526 /// "required": [
13527 /// "planned_amount"
13528 /// ],
13529 /// "properties": {
13530 /// "category_guid": {
13531 /// "examples": [
13532 /// "CAT-40faf068-abb4-405c-8f6a-e883ed541fff"
13533 /// ],
13534 /// "type": "string"
13535 /// },
13536 /// "item_type": {
13537 /// "examples": [
13538 /// 1
13539 /// ],
13540 /// "type": "number"
13541 /// },
13542 /// "planned_amount": {
13543 /// "examples": [
13544 /// 110
13545 /// ],
13546 /// "type": "number"
13547 /// },
13548 /// "scheduled_payment_guid": {
13549 /// "examples": [
13550 /// "SCP-c731988a-712f-4f83-9b3b-0aa5b3d5208b"
13551 /// ],
13552 /// "type": "string"
13553 /// },
13554 /// "top_level_category_guid": {
13555 /// "examples": [
13556 /// "CAT-9588eaad-90a4-bb5c-66c8-1812503d0db8"
13557 /// ],
13558 /// "type": "string"
13559 /// }
13560 /// }
13561 ///}
13562 /// ```
13563 /// </details>
13564 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
13565 pub struct SpendingPlanIterationItemCreateRequestBody {
13566 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13567 pub category_guid: ::std::option::Option<::std::string::String>,
13568 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13569 pub item_type: ::std::option::Option<f64>,
13570 pub planned_amount: f64,
13571 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13572 pub scheduled_payment_guid: ::std::option::Option<::std::string::String>,
13573 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13574 pub top_level_category_guid: ::std::option::Option<::std::string::String>,
13575 }
13576
13577 impl ::std::convert::From<&SpendingPlanIterationItemCreateRequestBody>
13578 for SpendingPlanIterationItemCreateRequestBody
13579 {
13580 fn from(value: &SpendingPlanIterationItemCreateRequestBody) -> Self {
13581 value.clone()
13582 }
13583 }
13584
13585 ///`SpendingPlanIterationItemResponse`
13586 ///
13587 /// <details><summary>JSON schema</summary>
13588 ///
13589 /// ```json
13590 ///{
13591 /// "type": "object",
13592 /// "properties": {
13593 /// "actual_amount": {
13594 /// "examples": [
13595 /// 345
13596 /// ],
13597 /// "type": [
13598 /// "number",
13599 /// "null"
13600 /// ]
13601 /// },
13602 /// "category_guid": {
13603 /// "examples": [
13604 /// "CAT-40faf068-abb4-405c-8f6a-e883ed541fff"
13605 /// ],
13606 /// "type": [
13607 /// "string",
13608 /// "null"
13609 /// ]
13610 /// },
13611 /// "created_at": {
13612 /// "examples": [
13613 /// "2016-10-13T18:08:00+00:00"
13614 /// ],
13615 /// "type": [
13616 /// "string",
13617 /// "null"
13618 /// ]
13619 /// },
13620 /// "guid": {
13621 /// "examples": [
13622 /// "SPL-e5f9a5bd-c5b3-4901-bdc0-62119b9db262"
13623 /// ],
13624 /// "type": [
13625 /// "string",
13626 /// "null"
13627 /// ]
13628 /// },
13629 /// "item_type": {
13630 /// "examples": [
13631 /// "1"
13632 /// ],
13633 /// "type": [
13634 /// "string",
13635 /// "null"
13636 /// ]
13637 /// },
13638 /// "planned_amount": {
13639 /// "examples": [
13640 /// 110
13641 /// ],
13642 /// "type": [
13643 /// "number",
13644 /// "null"
13645 /// ]
13646 /// },
13647 /// "scheduled_payment_guid": {
13648 /// "examples": [
13649 /// "SCP-c731988a-712f-4f83-9b3b-0aa5b3d5208b"
13650 /// ],
13651 /// "type": [
13652 /// "string",
13653 /// "null"
13654 /// ]
13655 /// },
13656 /// "spending_plan_iteration_guid": {
13657 /// "examples": [
13658 /// "SPI-848e6648-3fa3-4632-ac8f-e65f03167102"
13659 /// ],
13660 /// "type": [
13661 /// "string",
13662 /// "null"
13663 /// ]
13664 /// },
13665 /// "top_level_category_guid": {
13666 /// "examples": [
13667 /// "CAT-9588eaad-90a4-bb5c-66c8-1812503d0db8"
13668 /// ],
13669 /// "type": [
13670 /// "string",
13671 /// "null"
13672 /// ]
13673 /// },
13674 /// "transaction_guids": {
13675 /// "type": "array",
13676 /// "items": {
13677 /// "examples": [
13678 /// "TRN-265abee9-889b-af6a-c69b-25157db2bdd9"
13679 /// ],
13680 /// "type": [
13681 /// "string",
13682 /// "null"
13683 /// ]
13684 /// }
13685 /// },
13686 /// "updated_at": {
13687 /// "examples": [
13688 /// "2016-10-13T18:09:00+00:00"
13689 /// ],
13690 /// "type": [
13691 /// "string",
13692 /// "null"
13693 /// ]
13694 /// },
13695 /// "user_guid": {
13696 /// "examples": [
13697 /// "USR-fa7537f3-48aa-a683-a02a-b18940482f54"
13698 /// ],
13699 /// "type": [
13700 /// "string",
13701 /// "null"
13702 /// ]
13703 /// }
13704 /// }
13705 ///}
13706 /// ```
13707 /// </details>
13708 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
13709 pub struct SpendingPlanIterationItemResponse {
13710 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13711 pub actual_amount: ::std::option::Option<f64>,
13712 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13713 pub category_guid: ::std::option::Option<::std::string::String>,
13714 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13715 pub created_at: ::std::option::Option<::std::string::String>,
13716 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13717 pub guid: ::std::option::Option<::std::string::String>,
13718 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13719 pub item_type: ::std::option::Option<::std::string::String>,
13720 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13721 pub planned_amount: ::std::option::Option<f64>,
13722 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13723 pub scheduled_payment_guid: ::std::option::Option<::std::string::String>,
13724 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13725 pub spending_plan_iteration_guid: ::std::option::Option<::std::string::String>,
13726 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13727 pub top_level_category_guid: ::std::option::Option<::std::string::String>,
13728 #[serde(default, skip_serializing_if = "::std::vec::Vec::is_empty")]
13729 pub transaction_guids: ::std::vec::Vec<::std::option::Option<::std::string::String>>,
13730 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13731 pub updated_at: ::std::option::Option<::std::string::String>,
13732 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13733 pub user_guid: ::std::option::Option<::std::string::String>,
13734 }
13735
13736 impl ::std::convert::From<&SpendingPlanIterationItemResponse>
13737 for SpendingPlanIterationItemResponse
13738 {
13739 fn from(value: &SpendingPlanIterationItemResponse) -> Self {
13740 value.clone()
13741 }
13742 }
13743
13744 impl ::std::default::Default for SpendingPlanIterationItemResponse {
13745 fn default() -> Self {
13746 Self {
13747 actual_amount: Default::default(),
13748 category_guid: Default::default(),
13749 created_at: Default::default(),
13750 guid: Default::default(),
13751 item_type: Default::default(),
13752 planned_amount: Default::default(),
13753 scheduled_payment_guid: Default::default(),
13754 spending_plan_iteration_guid: Default::default(),
13755 top_level_category_guid: Default::default(),
13756 transaction_guids: Default::default(),
13757 updated_at: Default::default(),
13758 user_guid: Default::default(),
13759 }
13760 }
13761 }
13762
13763 ///`SpendingPlanIterationItemsResponseBody`
13764 ///
13765 /// <details><summary>JSON schema</summary>
13766 ///
13767 /// ```json
13768 ///{
13769 /// "type": "object",
13770 /// "properties": {
13771 /// "iteration_items": {
13772 /// "type": "array",
13773 /// "items": {
13774 /// "$ref": "#/components/schemas/SpendingPlanIterationItemResponse"
13775 /// }
13776 /// },
13777 /// "pagination": {
13778 /// "$ref": "#/components/schemas/PaginationResponse"
13779 /// }
13780 /// }
13781 ///}
13782 /// ```
13783 /// </details>
13784 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
13785 pub struct SpendingPlanIterationItemsResponseBody {
13786 #[serde(default, skip_serializing_if = "::std::vec::Vec::is_empty")]
13787 pub iteration_items: ::std::vec::Vec<SpendingPlanIterationItemResponse>,
13788 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13789 pub pagination: ::std::option::Option<PaginationResponse>,
13790 }
13791
13792 impl ::std::convert::From<&SpendingPlanIterationItemsResponseBody>
13793 for SpendingPlanIterationItemsResponseBody
13794 {
13795 fn from(value: &SpendingPlanIterationItemsResponseBody) -> Self {
13796 value.clone()
13797 }
13798 }
13799
13800 impl ::std::default::Default for SpendingPlanIterationItemsResponseBody {
13801 fn default() -> Self {
13802 Self {
13803 iteration_items: Default::default(),
13804 pagination: Default::default(),
13805 }
13806 }
13807 }
13808
13809 ///`SpendingPlanIterationResponse`
13810 ///
13811 /// <details><summary>JSON schema</summary>
13812 ///
13813 /// ```json
13814 ///{
13815 /// "type": "object",
13816 /// "properties": {
13817 /// "created_at": {
13818 /// "examples": [
13819 /// "2016-10-13T18:08:00+00:00"
13820 /// ],
13821 /// "type": [
13822 /// "string",
13823 /// "null"
13824 /// ]
13825 /// },
13826 /// "end_on": {
13827 /// "examples": [
13828 /// "2023-05-31"
13829 /// ],
13830 /// "type": [
13831 /// "string",
13832 /// "null"
13833 /// ]
13834 /// },
13835 /// "guid": {
13836 /// "examples": [
13837 /// "SPI-848e6648-3fa3-4632-ac8f-e65f03167102"
13838 /// ],
13839 /// "type": [
13840 /// "string",
13841 /// "null"
13842 /// ]
13843 /// },
13844 /// "iteration_number": {
13845 /// "examples": [
13846 /// 1
13847 /// ],
13848 /// "type": [
13849 /// "integer",
13850 /// "null"
13851 /// ]
13852 /// },
13853 /// "spending_plan_guid": {
13854 /// "examples": [
13855 /// "SPL-dbfe201d-c341-4bff-93c0-62a918d0b600"
13856 /// ],
13857 /// "type": [
13858 /// "string",
13859 /// "null"
13860 /// ]
13861 /// },
13862 /// "start_on": {
13863 /// "examples": [
13864 /// "2023-05-01"
13865 /// ],
13866 /// "type": [
13867 /// "string",
13868 /// "null"
13869 /// ]
13870 /// },
13871 /// "updated_at": {
13872 /// "examples": [
13873 /// "2016-10-13T18:09:00+00:00"
13874 /// ],
13875 /// "type": [
13876 /// "string",
13877 /// "null"
13878 /// ]
13879 /// },
13880 /// "user_guid": {
13881 /// "examples": [
13882 /// "USR-72086f59-6684-4adf-8f29-c4d32db43cd7"
13883 /// ],
13884 /// "type": [
13885 /// "string",
13886 /// "null"
13887 /// ]
13888 /// }
13889 /// }
13890 ///}
13891 /// ```
13892 /// </details>
13893 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
13894 pub struct SpendingPlanIterationResponse {
13895 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13896 pub created_at: ::std::option::Option<::std::string::String>,
13897 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13898 pub end_on: ::std::option::Option<::std::string::String>,
13899 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13900 pub guid: ::std::option::Option<::std::string::String>,
13901 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13902 pub iteration_number: ::std::option::Option<i64>,
13903 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13904 pub spending_plan_guid: ::std::option::Option<::std::string::String>,
13905 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13906 pub start_on: ::std::option::Option<::std::string::String>,
13907 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13908 pub updated_at: ::std::option::Option<::std::string::String>,
13909 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13910 pub user_guid: ::std::option::Option<::std::string::String>,
13911 }
13912
13913 impl ::std::convert::From<&SpendingPlanIterationResponse> for SpendingPlanIterationResponse {
13914 fn from(value: &SpendingPlanIterationResponse) -> Self {
13915 value.clone()
13916 }
13917 }
13918
13919 impl ::std::default::Default for SpendingPlanIterationResponse {
13920 fn default() -> Self {
13921 Self {
13922 created_at: Default::default(),
13923 end_on: Default::default(),
13924 guid: Default::default(),
13925 iteration_number: Default::default(),
13926 spending_plan_guid: Default::default(),
13927 start_on: Default::default(),
13928 updated_at: Default::default(),
13929 user_guid: Default::default(),
13930 }
13931 }
13932 }
13933
13934 ///`SpendingPlanIterationsResponse`
13935 ///
13936 /// <details><summary>JSON schema</summary>
13937 ///
13938 /// ```json
13939 ///{
13940 /// "type": "object",
13941 /// "properties": {
13942 /// "iterations": {
13943 /// "type": "array",
13944 /// "items": {
13945 /// "$ref": "#/components/schemas/SpendingPlanIterationResponse"
13946 /// }
13947 /// },
13948 /// "pagination": {
13949 /// "$ref": "#/components/schemas/PaginationResponse"
13950 /// }
13951 /// }
13952 ///}
13953 /// ```
13954 /// </details>
13955 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
13956 pub struct SpendingPlanIterationsResponse {
13957 #[serde(default, skip_serializing_if = "::std::vec::Vec::is_empty")]
13958 pub iterations: ::std::vec::Vec<SpendingPlanIterationResponse>,
13959 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
13960 pub pagination: ::std::option::Option<PaginationResponse>,
13961 }
13962
13963 impl ::std::convert::From<&SpendingPlanIterationsResponse> for SpendingPlanIterationsResponse {
13964 fn from(value: &SpendingPlanIterationsResponse) -> Self {
13965 value.clone()
13966 }
13967 }
13968
13969 impl ::std::default::Default for SpendingPlanIterationsResponse {
13970 fn default() -> Self {
13971 Self {
13972 iterations: Default::default(),
13973 pagination: Default::default(),
13974 }
13975 }
13976 }
13977
13978 ///`SpendingPlanResponse`
13979 ///
13980 /// <details><summary>JSON schema</summary>
13981 ///
13982 /// ```json
13983 ///{
13984 /// "type": "object",
13985 /// "properties": {
13986 /// "created_at": {
13987 /// "examples": [
13988 /// "2016-10-13T18:08:00+00:00"
13989 /// ],
13990 /// "type": [
13991 /// "string",
13992 /// "null"
13993 /// ]
13994 /// },
13995 /// "current_iteration_number": {
13996 /// "examples": [
13997 /// 1
13998 /// ],
13999 /// "type": [
14000 /// "integer",
14001 /// "null"
14002 /// ]
14003 /// },
14004 /// "guid": {
14005 /// "examples": [
14006 /// "SPL-e5f9a5bd-c5b3-4901-bdc0-62119b9db262"
14007 /// ],
14008 /// "type": [
14009 /// "string",
14010 /// "null"
14011 /// ]
14012 /// },
14013 /// "updated_at": {
14014 /// "examples": [
14015 /// "2016-10-13T18:09:00+00:00"
14016 /// ],
14017 /// "type": [
14018 /// "string",
14019 /// "null"
14020 /// ]
14021 /// },
14022 /// "user_guid": {
14023 /// "examples": [
14024 /// "USR-fa7537f3-48aa-a683-a02a-b18940482f54"
14025 /// ],
14026 /// "type": [
14027 /// "string",
14028 /// "null"
14029 /// ]
14030 /// }
14031 /// }
14032 ///}
14033 /// ```
14034 /// </details>
14035 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
14036 pub struct SpendingPlanResponse {
14037 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
14038 pub created_at: ::std::option::Option<::std::string::String>,
14039 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
14040 pub current_iteration_number: ::std::option::Option<i64>,
14041 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
14042 pub guid: ::std::option::Option<::std::string::String>,
14043 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
14044 pub updated_at: ::std::option::Option<::std::string::String>,
14045 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
14046 pub user_guid: ::std::option::Option<::std::string::String>,
14047 }
14048
14049 impl ::std::convert::From<&SpendingPlanResponse> for SpendingPlanResponse {
14050 fn from(value: &SpendingPlanResponse) -> Self {
14051 value.clone()
14052 }
14053 }
14054
14055 impl ::std::default::Default for SpendingPlanResponse {
14056 fn default() -> Self {
14057 Self {
14058 created_at: Default::default(),
14059 current_iteration_number: Default::default(),
14060 guid: Default::default(),
14061 updated_at: Default::default(),
14062 user_guid: Default::default(),
14063 }
14064 }
14065 }
14066
14067 ///`SpendingPlansResponseBody`
14068 ///
14069 /// <details><summary>JSON schema</summary>
14070 ///
14071 /// ```json
14072 ///{
14073 /// "type": "object",
14074 /// "properties": {
14075 /// "pagination": {
14076 /// "$ref": "#/components/schemas/PaginationResponse"
14077 /// },
14078 /// "spending_plans": {
14079 /// "type": "array",
14080 /// "items": {
14081 /// "$ref": "#/components/schemas/SpendingPlanResponse"
14082 /// }
14083 /// }
14084 /// }
14085 ///}
14086 /// ```
14087 /// </details>
14088 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
14089 pub struct SpendingPlansResponseBody {
14090 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
14091 pub pagination: ::std::option::Option<PaginationResponse>,
14092 #[serde(default, skip_serializing_if = "::std::vec::Vec::is_empty")]
14093 pub spending_plans: ::std::vec::Vec<SpendingPlanResponse>,
14094 }
14095
14096 impl ::std::convert::From<&SpendingPlansResponseBody> for SpendingPlansResponseBody {
14097 fn from(value: &SpendingPlansResponseBody) -> Self {
14098 value.clone()
14099 }
14100 }
14101
14102 impl ::std::default::Default for SpendingPlansResponseBody {
14103 fn default() -> Self {
14104 Self {
14105 pagination: Default::default(),
14106 spending_plans: Default::default(),
14107 }
14108 }
14109 }
14110
14111 ///`SplitTransactionRequest`
14112 ///
14113 /// <details><summary>JSON schema</summary>
14114 ///
14115 /// ```json
14116 ///{
14117 /// "required": [
14118 /// "amount"
14119 /// ],
14120 /// "properties": {
14121 /// "amount": {
14122 /// "description": "Amount of money you want to re-categorize.",
14123 /// "examples": [
14124 /// 54.19
14125 /// ],
14126 /// "type": "number"
14127 /// },
14128 /// "category_guid": {
14129 /// "description": "Unique identifier of the category.",
14130 /// "examples": [
14131 /// "CAT-b6d61a19-30a7-e852-2703-bdfb4072289e"
14132 /// ],
14133 /// "type": "string"
14134 /// },
14135 /// "description": {
14136 /// "description": "Description for the split transaction.",
14137 /// "examples": [
14138 /// "Chevron Gas"
14139 /// ],
14140 /// "type": "string"
14141 /// },
14142 /// "memo": {
14143 /// "description": "Memo for the split transaction",
14144 /// "examples": [
14145 /// "Chips and Soda"
14146 /// ],
14147 /// "type": "string"
14148 /// }
14149 /// }
14150 ///}
14151 /// ```
14152 /// </details>
14153 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
14154 pub struct SplitTransactionRequest {
14155 pub amount: f64,
14156 ///Unique identifier of the category.
14157 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
14158 pub category_guid: ::std::option::Option<::std::string::String>,
14159 ///Description for the split transaction.
14160 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
14161 pub description: ::std::option::Option<::std::string::String>,
14162 ///Memo for the split transaction
14163 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
14164 pub memo: ::std::option::Option<::std::string::String>,
14165 }
14166
14167 impl ::std::convert::From<&SplitTransactionRequest> for SplitTransactionRequest {
14168 fn from(value: &SplitTransactionRequest) -> Self {
14169 value.clone()
14170 }
14171 }
14172
14173 ///`SplitTransactionRequestBody`
14174 ///
14175 /// <details><summary>JSON schema</summary>
14176 ///
14177 /// ```json
14178 ///{
14179 /// "type": "object",
14180 /// "required": [
14181 /// "transactions"
14182 /// ],
14183 /// "properties": {
14184 /// "transactions": {
14185 /// "$ref": "#/components/schemas/SplitTransactionRequest"
14186 /// }
14187 /// }
14188 ///}
14189 /// ```
14190 /// </details>
14191 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
14192 pub struct SplitTransactionRequestBody {
14193 pub transactions: SplitTransactionRequest,
14194 }
14195
14196 impl ::std::convert::From<&SplitTransactionRequestBody> for SplitTransactionRequestBody {
14197 fn from(value: &SplitTransactionRequestBody) -> Self {
14198 value.clone()
14199 }
14200 }
14201
14202 ///`SplitTransactionsResponseBody`
14203 ///
14204 /// <details><summary>JSON schema</summary>
14205 ///
14206 /// ```json
14207 ///{
14208 /// "type": "object",
14209 /// "properties": {
14210 /// "transactions": {
14211 /// "type": "array",
14212 /// "items": {
14213 /// "$ref": "#/components/schemas/TransactionResponse"
14214 /// }
14215 /// }
14216 /// }
14217 ///}
14218 /// ```
14219 /// </details>
14220 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
14221 pub struct SplitTransactionsResponseBody {
14222 #[serde(default, skip_serializing_if = "::std::vec::Vec::is_empty")]
14223 pub transactions: ::std::vec::Vec<TransactionResponse>,
14224 }
14225
14226 impl ::std::convert::From<&SplitTransactionsResponseBody> for SplitTransactionsResponseBody {
14227 fn from(value: &SplitTransactionsResponseBody) -> Self {
14228 value.clone()
14229 }
14230 }
14231
14232 impl ::std::default::Default for SplitTransactionsResponseBody {
14233 fn default() -> Self {
14234 Self {
14235 transactions: Default::default(),
14236 }
14237 }
14238 }
14239
14240 ///`StatementResponse`
14241 ///
14242 /// <details><summary>JSON schema</summary>
14243 ///
14244 /// ```json
14245 ///{
14246 /// "type": "object",
14247 /// "properties": {
14248 /// "account_guid": {
14249 /// "examples": [
14250 /// "ACT-06d7f44b-caae-0f6e-1384-01f52e75dcb1"
14251 /// ],
14252 /// "type": [
14253 /// "string",
14254 /// "null"
14255 /// ]
14256 /// },
14257 /// "content_hash": {
14258 /// "examples": [
14259 /// "ca53785b812d00ef821c3d94bfd6e5bbc0020504410589b7ea8552169f021981"
14260 /// ],
14261 /// "type": [
14262 /// "string",
14263 /// "null"
14264 /// ]
14265 /// },
14266 /// "created_at": {
14267 /// "examples": [
14268 /// "2016-10-13T18:08:00+00:00"
14269 /// ],
14270 /// "type": [
14271 /// "string",
14272 /// "null"
14273 /// ]
14274 /// },
14275 /// "guid": {
14276 /// "examples": [
14277 /// "STA-737a344b-caae-0f6e-1384-01f52e75dcb1"
14278 /// ],
14279 /// "type": [
14280 /// "string",
14281 /// "null"
14282 /// ]
14283 /// },
14284 /// "member_guid": {
14285 /// "examples": [
14286 /// "MBR-7c6f361b-e582-15b6-60c0-358f12466b4b"
14287 /// ],
14288 /// "type": [
14289 /// "string",
14290 /// "null"
14291 /// ]
14292 /// },
14293 /// "updated_at": {
14294 /// "examples": [
14295 /// "2016-10-13T18:09:00+00:00"
14296 /// ],
14297 /// "type": [
14298 /// "string",
14299 /// "null"
14300 /// ]
14301 /// },
14302 /// "uri": {
14303 /// "examples": [
14304 /// "uri/to/statement"
14305 /// ],
14306 /// "type": [
14307 /// "string",
14308 /// "null"
14309 /// ]
14310 /// },
14311 /// "user_guid": {
14312 /// "examples": [
14313 /// "USR-fa7537f3-48aa-a683-a02a-b18940482f54"
14314 /// ],
14315 /// "type": [
14316 /// "string",
14317 /// "null"
14318 /// ]
14319 /// }
14320 /// }
14321 ///}
14322 /// ```
14323 /// </details>
14324 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
14325 pub struct StatementResponse {
14326 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
14327 pub account_guid: ::std::option::Option<::std::string::String>,
14328 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
14329 pub content_hash: ::std::option::Option<::std::string::String>,
14330 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
14331 pub created_at: ::std::option::Option<::std::string::String>,
14332 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
14333 pub guid: ::std::option::Option<::std::string::String>,
14334 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
14335 pub member_guid: ::std::option::Option<::std::string::String>,
14336 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
14337 pub updated_at: ::std::option::Option<::std::string::String>,
14338 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
14339 pub uri: ::std::option::Option<::std::string::String>,
14340 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
14341 pub user_guid: ::std::option::Option<::std::string::String>,
14342 }
14343
14344 impl ::std::convert::From<&StatementResponse> for StatementResponse {
14345 fn from(value: &StatementResponse) -> Self {
14346 value.clone()
14347 }
14348 }
14349
14350 impl ::std::default::Default for StatementResponse {
14351 fn default() -> Self {
14352 Self {
14353 account_guid: Default::default(),
14354 content_hash: Default::default(),
14355 created_at: Default::default(),
14356 guid: Default::default(),
14357 member_guid: Default::default(),
14358 updated_at: Default::default(),
14359 uri: Default::default(),
14360 user_guid: Default::default(),
14361 }
14362 }
14363 }
14364
14365 ///`StatementResponseBody`
14366 ///
14367 /// <details><summary>JSON schema</summary>
14368 ///
14369 /// ```json
14370 ///{
14371 /// "type": "object",
14372 /// "properties": {
14373 /// "statement": {
14374 /// "$ref": "#/components/schemas/StatementResponse"
14375 /// }
14376 /// }
14377 ///}
14378 /// ```
14379 /// </details>
14380 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
14381 pub struct StatementResponseBody {
14382 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
14383 pub statement: ::std::option::Option<StatementResponse>,
14384 }
14385
14386 impl ::std::convert::From<&StatementResponseBody> for StatementResponseBody {
14387 fn from(value: &StatementResponseBody) -> Self {
14388 value.clone()
14389 }
14390 }
14391
14392 impl ::std::default::Default for StatementResponseBody {
14393 fn default() -> Self {
14394 Self {
14395 statement: Default::default(),
14396 }
14397 }
14398 }
14399
14400 ///`StatementsResponseBody`
14401 ///
14402 /// <details><summary>JSON schema</summary>
14403 ///
14404 /// ```json
14405 ///{
14406 /// "type": "object",
14407 /// "properties": {
14408 /// "pagination": {
14409 /// "$ref": "#/components/schemas/PaginationResponse"
14410 /// },
14411 /// "statements": {
14412 /// "type": "array",
14413 /// "items": {
14414 /// "$ref": "#/components/schemas/StatementResponse"
14415 /// }
14416 /// }
14417 /// }
14418 ///}
14419 /// ```
14420 /// </details>
14421 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
14422 pub struct StatementsResponseBody {
14423 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
14424 pub pagination: ::std::option::Option<PaginationResponse>,
14425 #[serde(default, skip_serializing_if = "::std::vec::Vec::is_empty")]
14426 pub statements: ::std::vec::Vec<StatementResponse>,
14427 }
14428
14429 impl ::std::convert::From<&StatementsResponseBody> for StatementsResponseBody {
14430 fn from(value: &StatementsResponseBody) -> Self {
14431 value.clone()
14432 }
14433 }
14434
14435 impl ::std::default::Default for StatementsResponseBody {
14436 fn default() -> Self {
14437 Self {
14438 pagination: Default::default(),
14439 statements: Default::default(),
14440 }
14441 }
14442 }
14443
14444 ///`TagCreateRequest`
14445 ///
14446 /// <details><summary>JSON schema</summary>
14447 ///
14448 /// ```json
14449 ///{
14450 /// "type": "object",
14451 /// "required": [
14452 /// "name"
14453 /// ],
14454 /// "properties": {
14455 /// "name": {
14456 /// "examples": [
14457 /// "MY TAG"
14458 /// ],
14459 /// "type": "string"
14460 /// }
14461 /// }
14462 ///}
14463 /// ```
14464 /// </details>
14465 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
14466 pub struct TagCreateRequest {
14467 pub name: ::std::string::String,
14468 }
14469
14470 impl ::std::convert::From<&TagCreateRequest> for TagCreateRequest {
14471 fn from(value: &TagCreateRequest) -> Self {
14472 value.clone()
14473 }
14474 }
14475
14476 ///`TagCreateRequestBody`
14477 ///
14478 /// <details><summary>JSON schema</summary>
14479 ///
14480 /// ```json
14481 ///{
14482 /// "type": "object",
14483 /// "properties": {
14484 /// "tag": {
14485 /// "$ref": "#/components/schemas/TagCreateRequest"
14486 /// }
14487 /// }
14488 ///}
14489 /// ```
14490 /// </details>
14491 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
14492 pub struct TagCreateRequestBody {
14493 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
14494 pub tag: ::std::option::Option<TagCreateRequest>,
14495 }
14496
14497 impl ::std::convert::From<&TagCreateRequestBody> for TagCreateRequestBody {
14498 fn from(value: &TagCreateRequestBody) -> Self {
14499 value.clone()
14500 }
14501 }
14502
14503 impl ::std::default::Default for TagCreateRequestBody {
14504 fn default() -> Self {
14505 Self {
14506 tag: Default::default(),
14507 }
14508 }
14509 }
14510
14511 ///`TagResponse`
14512 ///
14513 /// <details><summary>JSON schema</summary>
14514 ///
14515 /// ```json
14516 ///{
14517 /// "type": "object",
14518 /// "properties": {
14519 /// "guid": {
14520 /// "examples": [
14521 /// "TAG-aef36e72-6294-4c38-844d-e573e80aed52"
14522 /// ],
14523 /// "type": [
14524 /// "string",
14525 /// "null"
14526 /// ]
14527 /// },
14528 /// "name": {
14529 /// "examples": [
14530 /// "MY TAG"
14531 /// ],
14532 /// "type": [
14533 /// "string",
14534 /// "null"
14535 /// ]
14536 /// },
14537 /// "user_guid": {
14538 /// "examples": [
14539 /// "USR-11141024-90b3-1bce-cac9-c06ced52ab4c"
14540 /// ],
14541 /// "type": [
14542 /// "string",
14543 /// "null"
14544 /// ]
14545 /// }
14546 /// }
14547 ///}
14548 /// ```
14549 /// </details>
14550 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
14551 pub struct TagResponse {
14552 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
14553 pub guid: ::std::option::Option<::std::string::String>,
14554 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
14555 pub name: ::std::option::Option<::std::string::String>,
14556 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
14557 pub user_guid: ::std::option::Option<::std::string::String>,
14558 }
14559
14560 impl ::std::convert::From<&TagResponse> for TagResponse {
14561 fn from(value: &TagResponse) -> Self {
14562 value.clone()
14563 }
14564 }
14565
14566 impl ::std::default::Default for TagResponse {
14567 fn default() -> Self {
14568 Self {
14569 guid: Default::default(),
14570 name: Default::default(),
14571 user_guid: Default::default(),
14572 }
14573 }
14574 }
14575
14576 ///`TagResponseBody`
14577 ///
14578 /// <details><summary>JSON schema</summary>
14579 ///
14580 /// ```json
14581 ///{
14582 /// "type": "object",
14583 /// "properties": {
14584 /// "tag": {
14585 /// "$ref": "#/components/schemas/TagResponse"
14586 /// }
14587 /// }
14588 ///}
14589 /// ```
14590 /// </details>
14591 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
14592 pub struct TagResponseBody {
14593 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
14594 pub tag: ::std::option::Option<TagResponse>,
14595 }
14596
14597 impl ::std::convert::From<&TagResponseBody> for TagResponseBody {
14598 fn from(value: &TagResponseBody) -> Self {
14599 value.clone()
14600 }
14601 }
14602
14603 impl ::std::default::Default for TagResponseBody {
14604 fn default() -> Self {
14605 Self {
14606 tag: Default::default(),
14607 }
14608 }
14609 }
14610
14611 ///`TagUpdateRequest`
14612 ///
14613 /// <details><summary>JSON schema</summary>
14614 ///
14615 /// ```json
14616 ///{
14617 /// "type": "object",
14618 /// "required": [
14619 /// "name"
14620 /// ],
14621 /// "properties": {
14622 /// "name": {
14623 /// "examples": [
14624 /// "MY TAG"
14625 /// ],
14626 /// "type": "string"
14627 /// }
14628 /// }
14629 ///}
14630 /// ```
14631 /// </details>
14632 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
14633 pub struct TagUpdateRequest {
14634 pub name: ::std::string::String,
14635 }
14636
14637 impl ::std::convert::From<&TagUpdateRequest> for TagUpdateRequest {
14638 fn from(value: &TagUpdateRequest) -> Self {
14639 value.clone()
14640 }
14641 }
14642
14643 ///`TagUpdateRequestBody`
14644 ///
14645 /// <details><summary>JSON schema</summary>
14646 ///
14647 /// ```json
14648 ///{
14649 /// "type": "object",
14650 /// "properties": {
14651 /// "tag": {
14652 /// "$ref": "#/components/schemas/TagUpdateRequest"
14653 /// }
14654 /// }
14655 ///}
14656 /// ```
14657 /// </details>
14658 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
14659 pub struct TagUpdateRequestBody {
14660 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
14661 pub tag: ::std::option::Option<TagUpdateRequest>,
14662 }
14663
14664 impl ::std::convert::From<&TagUpdateRequestBody> for TagUpdateRequestBody {
14665 fn from(value: &TagUpdateRequestBody) -> Self {
14666 value.clone()
14667 }
14668 }
14669
14670 impl ::std::default::Default for TagUpdateRequestBody {
14671 fn default() -> Self {
14672 Self {
14673 tag: Default::default(),
14674 }
14675 }
14676 }
14677
14678 ///`TaggingCreateRequest`
14679 ///
14680 /// <details><summary>JSON schema</summary>
14681 ///
14682 /// ```json
14683 ///{
14684 /// "type": "object",
14685 /// "required": [
14686 /// "tag_guid",
14687 /// "transaction_guid"
14688 /// ],
14689 /// "properties": {
14690 /// "tag_guid": {
14691 /// "examples": [
14692 /// "TAG-40faf068-abb4-405c-8f6a-e883ed541fff"
14693 /// ],
14694 /// "type": "string"
14695 /// },
14696 /// "transaction_guid": {
14697 /// "examples": [
14698 /// "TRN-810828b0-5210-4878-9bd3-f4ce514f90c4"
14699 /// ],
14700 /// "type": "string"
14701 /// }
14702 /// }
14703 ///}
14704 /// ```
14705 /// </details>
14706 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
14707 pub struct TaggingCreateRequest {
14708 pub tag_guid: ::std::string::String,
14709 pub transaction_guid: ::std::string::String,
14710 }
14711
14712 impl ::std::convert::From<&TaggingCreateRequest> for TaggingCreateRequest {
14713 fn from(value: &TaggingCreateRequest) -> Self {
14714 value.clone()
14715 }
14716 }
14717
14718 ///`TaggingCreateRequestBody`
14719 ///
14720 /// <details><summary>JSON schema</summary>
14721 ///
14722 /// ```json
14723 ///{
14724 /// "type": "object",
14725 /// "properties": {
14726 /// "tagging": {
14727 /// "$ref": "#/components/schemas/TaggingCreateRequest"
14728 /// }
14729 /// }
14730 ///}
14731 /// ```
14732 /// </details>
14733 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
14734 pub struct TaggingCreateRequestBody {
14735 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
14736 pub tagging: ::std::option::Option<TaggingCreateRequest>,
14737 }
14738
14739 impl ::std::convert::From<&TaggingCreateRequestBody> for TaggingCreateRequestBody {
14740 fn from(value: &TaggingCreateRequestBody) -> Self {
14741 value.clone()
14742 }
14743 }
14744
14745 impl ::std::default::Default for TaggingCreateRequestBody {
14746 fn default() -> Self {
14747 Self {
14748 tagging: Default::default(),
14749 }
14750 }
14751 }
14752
14753 ///`TaggingResponse`
14754 ///
14755 /// <details><summary>JSON schema</summary>
14756 ///
14757 /// ```json
14758 ///{
14759 /// "type": "object",
14760 /// "properties": {
14761 /// "guid": {
14762 /// "examples": [
14763 /// "TGN-007f5486-17e1-45fc-8b87-8f03984430fe"
14764 /// ],
14765 /// "type": [
14766 /// "string",
14767 /// "null"
14768 /// ]
14769 /// },
14770 /// "member_is_managed_by_user": {
14771 /// "examples": [
14772 /// false
14773 /// ],
14774 /// "type": [
14775 /// "boolean",
14776 /// "null"
14777 /// ]
14778 /// },
14779 /// "tag_guid": {
14780 /// "examples": [
14781 /// "TAG-40faf068-abb4-405c-8f6a-e883ed541fff"
14782 /// ],
14783 /// "type": [
14784 /// "string",
14785 /// "null"
14786 /// ]
14787 /// },
14788 /// "transaction_guid": {
14789 /// "examples": [
14790 /// "TRN-810828b0-5210-4878-9bd3-f4ce514f90c4"
14791 /// ],
14792 /// "type": [
14793 /// "string",
14794 /// "null"
14795 /// ]
14796 /// },
14797 /// "user_guid": {
14798 /// "examples": [
14799 /// "USR-11141024-90b3-1bce-cac9-c06ced52ab4c"
14800 /// ],
14801 /// "type": [
14802 /// "string",
14803 /// "null"
14804 /// ]
14805 /// }
14806 /// }
14807 ///}
14808 /// ```
14809 /// </details>
14810 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
14811 pub struct TaggingResponse {
14812 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
14813 pub guid: ::std::option::Option<::std::string::String>,
14814 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
14815 pub member_is_managed_by_user: ::std::option::Option<bool>,
14816 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
14817 pub tag_guid: ::std::option::Option<::std::string::String>,
14818 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
14819 pub transaction_guid: ::std::option::Option<::std::string::String>,
14820 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
14821 pub user_guid: ::std::option::Option<::std::string::String>,
14822 }
14823
14824 impl ::std::convert::From<&TaggingResponse> for TaggingResponse {
14825 fn from(value: &TaggingResponse) -> Self {
14826 value.clone()
14827 }
14828 }
14829
14830 impl ::std::default::Default for TaggingResponse {
14831 fn default() -> Self {
14832 Self {
14833 guid: Default::default(),
14834 member_is_managed_by_user: Default::default(),
14835 tag_guid: Default::default(),
14836 transaction_guid: Default::default(),
14837 user_guid: Default::default(),
14838 }
14839 }
14840 }
14841
14842 ///`TaggingResponseBody`
14843 ///
14844 /// <details><summary>JSON schema</summary>
14845 ///
14846 /// ```json
14847 ///{
14848 /// "type": "object",
14849 /// "properties": {
14850 /// "tagging": {
14851 /// "$ref": "#/components/schemas/TaggingResponse"
14852 /// }
14853 /// }
14854 ///}
14855 /// ```
14856 /// </details>
14857 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
14858 pub struct TaggingResponseBody {
14859 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
14860 pub tagging: ::std::option::Option<TaggingResponse>,
14861 }
14862
14863 impl ::std::convert::From<&TaggingResponseBody> for TaggingResponseBody {
14864 fn from(value: &TaggingResponseBody) -> Self {
14865 value.clone()
14866 }
14867 }
14868
14869 impl ::std::default::Default for TaggingResponseBody {
14870 fn default() -> Self {
14871 Self {
14872 tagging: Default::default(),
14873 }
14874 }
14875 }
14876
14877 ///`TaggingUpdateRequest`
14878 ///
14879 /// <details><summary>JSON schema</summary>
14880 ///
14881 /// ```json
14882 ///{
14883 /// "type": "object",
14884 /// "required": [
14885 /// "tag_guid"
14886 /// ],
14887 /// "properties": {
14888 /// "tag_guid": {
14889 /// "examples": [
14890 /// "TAG-40faf068-abb4-405c-8f6a-e883ed541fff"
14891 /// ],
14892 /// "type": "string"
14893 /// }
14894 /// }
14895 ///}
14896 /// ```
14897 /// </details>
14898 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
14899 pub struct TaggingUpdateRequest {
14900 pub tag_guid: ::std::string::String,
14901 }
14902
14903 impl ::std::convert::From<&TaggingUpdateRequest> for TaggingUpdateRequest {
14904 fn from(value: &TaggingUpdateRequest) -> Self {
14905 value.clone()
14906 }
14907 }
14908
14909 ///`TaggingUpdateRequestBody`
14910 ///
14911 /// <details><summary>JSON schema</summary>
14912 ///
14913 /// ```json
14914 ///{
14915 /// "type": "object",
14916 /// "properties": {
14917 /// "tagging": {
14918 /// "$ref": "#/components/schemas/TaggingUpdateRequest"
14919 /// }
14920 /// }
14921 ///}
14922 /// ```
14923 /// </details>
14924 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
14925 pub struct TaggingUpdateRequestBody {
14926 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
14927 pub tagging: ::std::option::Option<TaggingUpdateRequest>,
14928 }
14929
14930 impl ::std::convert::From<&TaggingUpdateRequestBody> for TaggingUpdateRequestBody {
14931 fn from(value: &TaggingUpdateRequestBody) -> Self {
14932 value.clone()
14933 }
14934 }
14935
14936 impl ::std::default::Default for TaggingUpdateRequestBody {
14937 fn default() -> Self {
14938 Self {
14939 tagging: Default::default(),
14940 }
14941 }
14942 }
14943
14944 ///`TaggingsResponseBody`
14945 ///
14946 /// <details><summary>JSON schema</summary>
14947 ///
14948 /// ```json
14949 ///{
14950 /// "type": "object",
14951 /// "properties": {
14952 /// "pagination": {
14953 /// "$ref": "#/components/schemas/PaginationResponse"
14954 /// },
14955 /// "taggings": {
14956 /// "type": "array",
14957 /// "items": {
14958 /// "$ref": "#/components/schemas/TaggingResponse"
14959 /// }
14960 /// }
14961 /// }
14962 ///}
14963 /// ```
14964 /// </details>
14965 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
14966 pub struct TaggingsResponseBody {
14967 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
14968 pub pagination: ::std::option::Option<PaginationResponse>,
14969 #[serde(default, skip_serializing_if = "::std::vec::Vec::is_empty")]
14970 pub taggings: ::std::vec::Vec<TaggingResponse>,
14971 }
14972
14973 impl ::std::convert::From<&TaggingsResponseBody> for TaggingsResponseBody {
14974 fn from(value: &TaggingsResponseBody) -> Self {
14975 value.clone()
14976 }
14977 }
14978
14979 impl ::std::default::Default for TaggingsResponseBody {
14980 fn default() -> Self {
14981 Self {
14982 pagination: Default::default(),
14983 taggings: Default::default(),
14984 }
14985 }
14986 }
14987
14988 ///`TagsResponseBody`
14989 ///
14990 /// <details><summary>JSON schema</summary>
14991 ///
14992 /// ```json
14993 ///{
14994 /// "type": "object",
14995 /// "properties": {
14996 /// "pagination": {
14997 /// "$ref": "#/components/schemas/PaginationResponse"
14998 /// },
14999 /// "tags": {
15000 /// "type": "array",
15001 /// "items": {
15002 /// "$ref": "#/components/schemas/TagResponse"
15003 /// }
15004 /// }
15005 /// }
15006 ///}
15007 /// ```
15008 /// </details>
15009 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
15010 pub struct TagsResponseBody {
15011 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
15012 pub pagination: ::std::option::Option<PaginationResponse>,
15013 #[serde(default, skip_serializing_if = "::std::vec::Vec::is_empty")]
15014 pub tags: ::std::vec::Vec<TagResponse>,
15015 }
15016
15017 impl ::std::convert::From<&TagsResponseBody> for TagsResponseBody {
15018 fn from(value: &TagsResponseBody) -> Self {
15019 value.clone()
15020 }
15021 }
15022
15023 impl ::std::default::Default for TagsResponseBody {
15024 fn default() -> Self {
15025 Self {
15026 pagination: Default::default(),
15027 tags: Default::default(),
15028 }
15029 }
15030 }
15031
15032 ///`TokenRequestBody`
15033 ///
15034 /// <details><summary>JSON schema</summary>
15035 ///
15036 /// ```json
15037 ///{
15038 /// "type": "object",
15039 /// "properties": {
15040 /// "scope": {
15041 /// "$ref": "#/components/schemas/MemberElements"
15042 /// }
15043 /// }
15044 ///}
15045 /// ```
15046 /// </details>
15047 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
15048 pub struct TokenRequestBody {
15049 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
15050 pub scope: ::std::option::Option<MemberElements>,
15051 }
15052
15053 impl ::std::convert::From<&TokenRequestBody> for TokenRequestBody {
15054 fn from(value: &TokenRequestBody) -> Self {
15055 value.clone()
15056 }
15057 }
15058
15059 impl ::std::default::Default for TokenRequestBody {
15060 fn default() -> Self {
15061 Self {
15062 scope: Default::default(),
15063 }
15064 }
15065 }
15066
15067 ///`TokenResponse`
15068 ///
15069 /// <details><summary>JSON schema</summary>
15070 ///
15071 /// ```json
15072 ///{
15073 /// "properties": {
15074 /// "access_token": {
15075 /// "examples": [
15076 /// "i8FnF..."
15077 /// ],
15078 /// "type": "string"
15079 /// },
15080 /// "active": {
15081 /// "examples": [
15082 /// true
15083 /// ],
15084 /// "type": "boolean"
15085 /// },
15086 /// "expires_at": {
15087 /// "examples": [
15088 /// "2023-04-19T15:38:2800:00"
15089 /// ],
15090 /// "type": "string"
15091 /// },
15092 /// "payment_processor_guid": {
15093 /// "examples": [
15094 /// "PPR-084aa709-8218-4b5a-b3ab-70ffc7483daf"
15095 /// ],
15096 /// "type": "string"
15097 /// }
15098 /// }
15099 ///}
15100 /// ```
15101 /// </details>
15102 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
15103 pub struct TokenResponse {
15104 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
15105 pub access_token: ::std::option::Option<::std::string::String>,
15106 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
15107 pub active: ::std::option::Option<bool>,
15108 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
15109 pub expires_at: ::std::option::Option<::std::string::String>,
15110 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
15111 pub payment_processor_guid: ::std::option::Option<::std::string::String>,
15112 }
15113
15114 impl ::std::convert::From<&TokenResponse> for TokenResponse {
15115 fn from(value: &TokenResponse) -> Self {
15116 value.clone()
15117 }
15118 }
15119
15120 impl ::std::default::Default for TokenResponse {
15121 fn default() -> Self {
15122 Self {
15123 access_token: Default::default(),
15124 active: Default::default(),
15125 expires_at: Default::default(),
15126 payment_processor_guid: Default::default(),
15127 }
15128 }
15129 }
15130
15131 ///`TokenResponseBody`
15132 ///
15133 /// <details><summary>JSON schema</summary>
15134 ///
15135 /// ```json
15136 ///{
15137 /// "type": "object",
15138 /// "properties": {
15139 /// "tokens": {
15140 /// "items": {
15141 /// "$ref": "#/components/schemas/TokenResponse"
15142 /// }
15143 /// }
15144 /// }
15145 ///}
15146 /// ```
15147 /// </details>
15148 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
15149 pub struct TokenResponseBody {
15150 #[serde(default, skip_serializing_if = "::std::vec::Vec::is_empty")]
15151 pub tokens: ::std::vec::Vec<TokenResponse>,
15152 }
15153
15154 impl ::std::convert::From<&TokenResponseBody> for TokenResponseBody {
15155 fn from(value: &TokenResponseBody) -> Self {
15156 value.clone()
15157 }
15158 }
15159
15160 impl ::std::default::Default for TokenResponseBody {
15161 fn default() -> Self {
15162 Self {
15163 tokens: Default::default(),
15164 }
15165 }
15166 }
15167
15168 ///`TransactionCreateRequest`
15169 ///
15170 /// <details><summary>JSON schema</summary>
15171 ///
15172 /// ```json
15173 ///{
15174 /// "required": [
15175 /// "amount",
15176 /// "date",
15177 /// "description",
15178 /// "type"
15179 /// ],
15180 /// "properties": {
15181 /// "amount": {
15182 /// "examples": [
15183 /// 61.11
15184 /// ],
15185 /// "type": "number"
15186 /// },
15187 /// "category_guid": {
15188 /// "description": "Unique identifier of the category.",
15189 /// "examples": [
15190 /// "CAT-b6d61a19-30a7-e852-2703-bdfb4072289e"
15191 /// ],
15192 /// "type": "string"
15193 /// },
15194 /// "currency_code": {
15195 /// "examples": [
15196 /// "USD"
15197 /// ],
15198 /// "type": "string"
15199 /// },
15200 /// "date": {
15201 /// "examples": [
15202 /// "2016-10-06"
15203 /// ],
15204 /// "type": "string"
15205 /// },
15206 /// "description": {
15207 /// "examples": [
15208 /// "Whole foods"
15209 /// ],
15210 /// "type": "string"
15211 /// },
15212 /// "has_been_viewed": {
15213 /// "examples": [
15214 /// false
15215 /// ],
15216 /// "type": "boolean"
15217 /// },
15218 /// "is_hidden": {
15219 /// "examples": [
15220 /// false
15221 /// ],
15222 /// "type": "boolean"
15223 /// },
15224 /// "is_international": {
15225 /// "examples": [
15226 /// false
15227 /// ],
15228 /// "type": "boolean"
15229 /// },
15230 /// "memo": {
15231 /// "examples": [
15232 /// "This is a memo"
15233 /// ],
15234 /// "type": "string"
15235 /// },
15236 /// "metadata": {
15237 /// "examples": [
15238 /// "some metadata"
15239 /// ],
15240 /// "type": "string"
15241 /// },
15242 /// "skip_webhook": {
15243 /// "description": "When set to true, this parameter will prevent a
15244 /// webhook from being triggered by the request.",
15245 /// "examples": [
15246 /// true
15247 /// ],
15248 /// "type": "boolean"
15249 /// },
15250 /// "type": {
15251 /// "description": "The type of transaction, which must be CREDIT or
15252 /// DEBIT. See Transaction Fields for more information.",
15253 /// "examples": [
15254 /// "DEBIT"
15255 /// ],
15256 /// "type": "string"
15257 /// }
15258 /// }
15259 ///}
15260 /// ```
15261 /// </details>
15262 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
15263 pub struct TransactionCreateRequest {
15264 pub amount: f64,
15265 ///Unique identifier of the category.
15266 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
15267 pub category_guid: ::std::option::Option<::std::string::String>,
15268 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
15269 pub currency_code: ::std::option::Option<::std::string::String>,
15270 pub date: ::std::string::String,
15271 pub description: ::std::string::String,
15272 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
15273 pub has_been_viewed: ::std::option::Option<bool>,
15274 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
15275 pub is_hidden: ::std::option::Option<bool>,
15276 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
15277 pub is_international: ::std::option::Option<bool>,
15278 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
15279 pub memo: ::std::option::Option<::std::string::String>,
15280 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
15281 pub metadata: ::std::option::Option<::std::string::String>,
15282 ///When set to true, this parameter will prevent a webhook from being
15283 /// triggered by the request.
15284 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
15285 pub skip_webhook: ::std::option::Option<bool>,
15286 ///The type of transaction, which must be CREDIT or DEBIT. See
15287 /// Transaction Fields for more information.
15288 #[serde(rename = "type")]
15289 pub type_: ::std::string::String,
15290 }
15291
15292 impl ::std::convert::From<&TransactionCreateRequest> for TransactionCreateRequest {
15293 fn from(value: &TransactionCreateRequest) -> Self {
15294 value.clone()
15295 }
15296 }
15297
15298 ///`TransactionCreateRequestBody`
15299 ///
15300 /// <details><summary>JSON schema</summary>
15301 ///
15302 /// ```json
15303 ///{
15304 /// "type": "object",
15305 /// "properties": {
15306 /// "transaction": {
15307 /// "$ref": "#/components/schemas/TransactionCreateRequest"
15308 /// }
15309 /// }
15310 ///}
15311 /// ```
15312 /// </details>
15313 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
15314 pub struct TransactionCreateRequestBody {
15315 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
15316 pub transaction: ::std::option::Option<TransactionCreateRequest>,
15317 }
15318
15319 impl ::std::convert::From<&TransactionCreateRequestBody> for TransactionCreateRequestBody {
15320 fn from(value: &TransactionCreateRequestBody) -> Self {
15321 value.clone()
15322 }
15323 }
15324
15325 impl ::std::default::Default for TransactionCreateRequestBody {
15326 fn default() -> Self {
15327 Self {
15328 transaction: Default::default(),
15329 }
15330 }
15331 }
15332
15333 ///`TransactionCreateResponseBody`
15334 ///
15335 /// <details><summary>JSON schema</summary>
15336 ///
15337 /// ```json
15338 ///{
15339 /// "type": "object",
15340 /// "properties": {
15341 /// "account_guid": {
15342 /// "examples": [
15343 /// "ACT-06d7f44b-caae-0f6e-1384-01f52e75dcb1"
15344 /// ],
15345 /// "type": [
15346 /// "string",
15347 /// "null"
15348 /// ]
15349 /// },
15350 /// "account_id": {
15351 /// "examples": [
15352 /// "account123"
15353 /// ],
15354 /// "type": [
15355 /// "string",
15356 /// "null"
15357 /// ]
15358 /// },
15359 /// "amount": {
15360 /// "examples": [
15361 /// 61.11
15362 /// ],
15363 /// "type": "number"
15364 /// },
15365 /// "category": {
15366 /// "examples": [
15367 /// "Groceries"
15368 /// ],
15369 /// "type": [
15370 /// "string",
15371 /// "null"
15372 /// ]
15373 /// },
15374 /// "category_guid": {
15375 /// "examples": [
15376 /// "CAT-b6d61a19-30a7-e852-2703-bdfb4072289e"
15377 /// ],
15378 /// "type": [
15379 /// "string",
15380 /// "null"
15381 /// ]
15382 /// },
15383 /// "check_number_string": {
15384 /// "type": [
15385 /// "string",
15386 /// "null"
15387 /// ]
15388 /// },
15389 /// "created_at": {
15390 /// "examples": [
15391 /// "2016-10-08T09:43:42.000Z"
15392 /// ],
15393 /// "type": [
15394 /// "string",
15395 /// "null"
15396 /// ]
15397 /// },
15398 /// "currency_code": {
15399 /// "examples": [
15400 /// "USD"
15401 /// ],
15402 /// "type": [
15403 /// "string",
15404 /// "null"
15405 /// ]
15406 /// },
15407 /// "date": {
15408 /// "examples": [
15409 /// "2016-10-06T00:00:00.000Z"
15410 /// ],
15411 /// "type": [
15412 /// "string",
15413 /// "null"
15414 /// ]
15415 /// },
15416 /// "description": {
15417 /// "examples": [
15418 /// "Whole foods"
15419 /// ],
15420 /// "type": [
15421 /// "string",
15422 /// "null"
15423 /// ]
15424 /// },
15425 /// "extended_transaction_type": {
15426 /// "type": [
15427 /// "string",
15428 /// "null"
15429 /// ]
15430 /// },
15431 /// "guid": {
15432 /// "examples": [
15433 /// "TRN-265abee9-889b-af6a-c69b-25157db2bdd9"
15434 /// ],
15435 /// "type": [
15436 /// "string",
15437 /// "null"
15438 /// ]
15439 /// },
15440 /// "id": {
15441 /// "type": [
15442 /// "string",
15443 /// "null"
15444 /// ]
15445 /// },
15446 /// "is_bill_pay": {
15447 /// "examples": [
15448 /// false
15449 /// ],
15450 /// "type": [
15451 /// "boolean",
15452 /// "null"
15453 /// ]
15454 /// },
15455 /// "is_direct_deposit": {
15456 /// "examples": [
15457 /// false
15458 /// ],
15459 /// "type": [
15460 /// "boolean",
15461 /// "null"
15462 /// ]
15463 /// },
15464 /// "is_expense": {
15465 /// "examples": [
15466 /// true
15467 /// ],
15468 /// "type": [
15469 /// "boolean",
15470 /// "null"
15471 /// ]
15472 /// },
15473 /// "is_fee": {
15474 /// "examples": [
15475 /// false
15476 /// ],
15477 /// "type": [
15478 /// "boolean",
15479 /// "null"
15480 /// ]
15481 /// },
15482 /// "is_income": {
15483 /// "examples": [
15484 /// false
15485 /// ],
15486 /// "type": [
15487 /// "boolean",
15488 /// "null"
15489 /// ]
15490 /// },
15491 /// "is_international": {
15492 /// "examples": [
15493 /// false
15494 /// ],
15495 /// "type": [
15496 /// "boolean",
15497 /// "null"
15498 /// ]
15499 /// },
15500 /// "is_manual": {
15501 /// "examples": [
15502 /// true
15503 /// ],
15504 /// "type": [
15505 /// "boolean",
15506 /// "null"
15507 /// ]
15508 /// },
15509 /// "is_overdraft_fee": {
15510 /// "examples": [
15511 /// false
15512 /// ],
15513 /// "type": [
15514 /// "boolean",
15515 /// "null"
15516 /// ]
15517 /// },
15518 /// "is_payroll_advance": {
15519 /// "examples": [
15520 /// false
15521 /// ],
15522 /// "type": [
15523 /// "boolean",
15524 /// "null"
15525 /// ]
15526 /// },
15527 /// "is_recurring": {
15528 /// "type": [
15529 /// "boolean",
15530 /// "null"
15531 /// ]
15532 /// },
15533 /// "is_subscription": {
15534 /// "examples": [
15535 /// false
15536 /// ],
15537 /// "type": [
15538 /// "boolean",
15539 /// "null"
15540 /// ]
15541 /// },
15542 /// "latitude": {
15543 /// "type": [
15544 /// "number",
15545 /// "null"
15546 /// ]
15547 /// },
15548 /// "localized_description": {
15549 /// "type": [
15550 /// "string",
15551 /// "null"
15552 /// ]
15553 /// },
15554 /// "localized_memo": {
15555 /// "type": [
15556 /// "string",
15557 /// "null"
15558 /// ]
15559 /// },
15560 /// "longitude": {
15561 /// "type": [
15562 /// "number",
15563 /// "null"
15564 /// ]
15565 /// },
15566 /// "member_guid": {
15567 /// "examples": [
15568 /// "MBR-7c6f361b-e582-15b6-60c0-358f12466b4b"
15569 /// ],
15570 /// "type": [
15571 /// "string",
15572 /// "null"
15573 /// ]
15574 /// },
15575 /// "member_is_managed_by_user": {
15576 /// "examples": [
15577 /// true
15578 /// ],
15579 /// "type": [
15580 /// "boolean",
15581 /// "null"
15582 /// ]
15583 /// },
15584 /// "memo": {
15585 /// "examples": [
15586 /// "This is a memo"
15587 /// ],
15588 /// "type": [
15589 /// "string",
15590 /// "null"
15591 /// ]
15592 /// },
15593 /// "merchant_category_code": {
15594 /// "type": [
15595 /// "integer",
15596 /// "null"
15597 /// ]
15598 /// },
15599 /// "merchant_guid": {
15600 /// "type": [
15601 /// "string",
15602 /// "null"
15603 /// ]
15604 /// },
15605 /// "merchant_location_guid": {
15606 /// "type": [
15607 /// "string",
15608 /// "null"
15609 /// ]
15610 /// },
15611 /// "metadata": {
15612 /// "examples": [
15613 /// "some metadata"
15614 /// ],
15615 /// "type": [
15616 /// "string",
15617 /// "null"
15618 /// ]
15619 /// },
15620 /// "original_description": {
15621 /// "type": [
15622 /// "string",
15623 /// "null"
15624 /// ]
15625 /// },
15626 /// "posted_at": {
15627 /// "type": [
15628 /// "string",
15629 /// "null"
15630 /// ]
15631 /// },
15632 /// "status": {
15633 /// "type": [
15634 /// "string",
15635 /// "null"
15636 /// ]
15637 /// },
15638 /// "top_level_category": {
15639 /// "examples": [
15640 /// "Food & Dining"
15641 /// ],
15642 /// "type": [
15643 /// "string",
15644 /// "null"
15645 /// ]
15646 /// },
15647 /// "transacted_at": {
15648 /// "type": [
15649 /// "string",
15650 /// "null"
15651 /// ]
15652 /// },
15653 /// "type": {
15654 /// "examples": [
15655 /// "DEBIT"
15656 /// ],
15657 /// "type": "string"
15658 /// },
15659 /// "updated_at": {
15660 /// "examples": [
15661 /// "2016-10-08T05:49:12.000Z"
15662 /// ],
15663 /// "type": "string"
15664 /// },
15665 /// "user_guid": {
15666 /// "examples": [
15667 /// "USR-fa7537f3-48aa-a683-a02a-b18940482f54"
15668 /// ],
15669 /// "type": [
15670 /// "string",
15671 /// "null"
15672 /// ]
15673 /// },
15674 /// "user_id": {
15675 /// "examples": [
15676 /// "user123"
15677 /// ],
15678 /// "type": [
15679 /// "string",
15680 /// "null"
15681 /// ]
15682 /// }
15683 /// }
15684 ///}
15685 /// ```
15686 /// </details>
15687 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
15688 pub struct TransactionCreateResponseBody {
15689 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
15690 pub account_guid: ::std::option::Option<::std::string::String>,
15691 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
15692 pub account_id: ::std::option::Option<::std::string::String>,
15693 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
15694 pub amount: ::std::option::Option<f64>,
15695 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
15696 pub category: ::std::option::Option<::std::string::String>,
15697 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
15698 pub category_guid: ::std::option::Option<::std::string::String>,
15699 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
15700 pub check_number_string: ::std::option::Option<::std::string::String>,
15701 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
15702 pub created_at: ::std::option::Option<::std::string::String>,
15703 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
15704 pub currency_code: ::std::option::Option<::std::string::String>,
15705 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
15706 pub date: ::std::option::Option<::std::string::String>,
15707 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
15708 pub description: ::std::option::Option<::std::string::String>,
15709 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
15710 pub extended_transaction_type: ::std::option::Option<::std::string::String>,
15711 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
15712 pub guid: ::std::option::Option<::std::string::String>,
15713 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
15714 pub id: ::std::option::Option<::std::string::String>,
15715 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
15716 pub is_bill_pay: ::std::option::Option<bool>,
15717 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
15718 pub is_direct_deposit: ::std::option::Option<bool>,
15719 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
15720 pub is_expense: ::std::option::Option<bool>,
15721 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
15722 pub is_fee: ::std::option::Option<bool>,
15723 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
15724 pub is_income: ::std::option::Option<bool>,
15725 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
15726 pub is_international: ::std::option::Option<bool>,
15727 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
15728 pub is_manual: ::std::option::Option<bool>,
15729 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
15730 pub is_overdraft_fee: ::std::option::Option<bool>,
15731 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
15732 pub is_payroll_advance: ::std::option::Option<bool>,
15733 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
15734 pub is_recurring: ::std::option::Option<bool>,
15735 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
15736 pub is_subscription: ::std::option::Option<bool>,
15737 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
15738 pub latitude: ::std::option::Option<f64>,
15739 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
15740 pub localized_description: ::std::option::Option<::std::string::String>,
15741 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
15742 pub localized_memo: ::std::option::Option<::std::string::String>,
15743 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
15744 pub longitude: ::std::option::Option<f64>,
15745 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
15746 pub member_guid: ::std::option::Option<::std::string::String>,
15747 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
15748 pub member_is_managed_by_user: ::std::option::Option<bool>,
15749 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
15750 pub memo: ::std::option::Option<::std::string::String>,
15751 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
15752 pub merchant_category_code: ::std::option::Option<i64>,
15753 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
15754 pub merchant_guid: ::std::option::Option<::std::string::String>,
15755 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
15756 pub merchant_location_guid: ::std::option::Option<::std::string::String>,
15757 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
15758 pub metadata: ::std::option::Option<::std::string::String>,
15759 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
15760 pub original_description: ::std::option::Option<::std::string::String>,
15761 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
15762 pub posted_at: ::std::option::Option<::std::string::String>,
15763 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
15764 pub status: ::std::option::Option<::std::string::String>,
15765 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
15766 pub top_level_category: ::std::option::Option<::std::string::String>,
15767 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
15768 pub transacted_at: ::std::option::Option<::std::string::String>,
15769 #[serde(
15770 rename = "type",
15771 default,
15772 skip_serializing_if = "::std::option::Option::is_none"
15773 )]
15774 pub type_: ::std::option::Option<::std::string::String>,
15775 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
15776 pub updated_at: ::std::option::Option<::std::string::String>,
15777 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
15778 pub user_guid: ::std::option::Option<::std::string::String>,
15779 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
15780 pub user_id: ::std::option::Option<::std::string::String>,
15781 }
15782
15783 impl ::std::convert::From<&TransactionCreateResponseBody> for TransactionCreateResponseBody {
15784 fn from(value: &TransactionCreateResponseBody) -> Self {
15785 value.clone()
15786 }
15787 }
15788
15789 impl ::std::default::Default for TransactionCreateResponseBody {
15790 fn default() -> Self {
15791 Self {
15792 account_guid: Default::default(),
15793 account_id: Default::default(),
15794 amount: Default::default(),
15795 category: Default::default(),
15796 category_guid: Default::default(),
15797 check_number_string: Default::default(),
15798 created_at: Default::default(),
15799 currency_code: Default::default(),
15800 date: Default::default(),
15801 description: Default::default(),
15802 extended_transaction_type: Default::default(),
15803 guid: Default::default(),
15804 id: Default::default(),
15805 is_bill_pay: Default::default(),
15806 is_direct_deposit: Default::default(),
15807 is_expense: Default::default(),
15808 is_fee: Default::default(),
15809 is_income: Default::default(),
15810 is_international: Default::default(),
15811 is_manual: Default::default(),
15812 is_overdraft_fee: Default::default(),
15813 is_payroll_advance: Default::default(),
15814 is_recurring: Default::default(),
15815 is_subscription: Default::default(),
15816 latitude: Default::default(),
15817 localized_description: Default::default(),
15818 localized_memo: Default::default(),
15819 longitude: Default::default(),
15820 member_guid: Default::default(),
15821 member_is_managed_by_user: Default::default(),
15822 memo: Default::default(),
15823 merchant_category_code: Default::default(),
15824 merchant_guid: Default::default(),
15825 merchant_location_guid: Default::default(),
15826 metadata: Default::default(),
15827 original_description: Default::default(),
15828 posted_at: Default::default(),
15829 status: Default::default(),
15830 top_level_category: Default::default(),
15831 transacted_at: Default::default(),
15832 type_: Default::default(),
15833 updated_at: Default::default(),
15834 user_guid: Default::default(),
15835 user_id: Default::default(),
15836 }
15837 }
15838 }
15839
15840 ///`TransactionIncludesResponse`
15841 ///
15842 /// <details><summary>JSON schema</summary>
15843 ///
15844 /// ```json
15845 ///{
15846 /// "type": "object",
15847 /// "allOf": [
15848 /// {
15849 /// "$ref": "#/components/schemas/TransactionResponse"
15850 /// },
15851 /// {
15852 /// "properties": {
15853 /// "classification": {
15854 /// "type": [
15855 /// "object",
15856 /// "null"
15857 /// ],
15858 /// "properties": {
15859 /// "guid": {
15860 /// "examples": [
15861 /// "MNC-3ad50f86-60d0-4545-a1f9-e66c2ac40f69"
15862 /// ],
15863 /// "type": "string"
15864 /// },
15865 /// "parent_class": {
15866 /// "examples": [
15867 /// "Deposit"
15868 /// ],
15869 /// "type": "string",
15870 /// "enum": [
15871 /// "Payroll",
15872 /// "Deposit",
15873 /// "Savings",
15874 /// "Transfer",
15875 /// "Refunds",
15876 /// "Spend",
15877 /// "Investment",
15878 /// "Buy",
15879 /// "Sell",
15880 /// "Income",
15881 /// "Fees",
15882 /// "Expenses",
15883 /// "Corporate Actions",
15884 /// "Other"
15885 /// ]
15886 /// }
15887 /// }
15888 /// },
15889 /// "geolocation": {
15890 /// "type": [
15891 /// "object",
15892 /// "null"
15893 /// ],
15894 /// "properties": {
15895 /// "city": {
15896 /// "examples": [
15897 /// "lehi"
15898 /// ],
15899 /// "type": "string"
15900 /// },
15901 /// "country": {
15902 /// "examples": [
15903 /// "us"
15904 /// ],
15905 /// "type": "string"
15906 /// },
15907 /// "postal code": {
15908 /// "examples": [
15909 /// "84043"
15910 /// ],
15911 /// "type": "string"
15912 /// },
15913 /// "state": {
15914 /// "examples": [
15915 /// "UT"
15916 /// ],
15917 /// "type": "string"
15918 /// }
15919 /// }
15920 /// },
15921 /// "merchant": {
15922 /// "type": [
15923 /// "object",
15924 /// "null"
15925 /// ],
15926 /// "properties": {
15927 /// "guid": {
15928 /// "examples": [
15929 /// "MCH-0c25f895-393c-42a4-9c18-95a0b26d4d84"
15930 /// ],
15931 /// "type": "string"
15932 /// },
15933 /// "logo_url": {
15934 /// "examples": [
15935 /// "https://content.mx.com/logos/merchants/MCH-0c25f895-393c-42a4-9c18-95a0b26d4d84.png"
15936 /// ],
15937 /// "type": "string"
15938 /// },
15939 /// "name": {
15940 /// "examples": [
15941 /// "MX"
15942 /// ],
15943 /// "type": "string"
15944 /// },
15945 /// "website_url": {
15946 /// "examples": [
15947 /// "https://www.mx.com"
15948 /// ],
15949 /// "type": "string"
15950 /// }
15951 /// }
15952 /// },
15953 /// "repeating_transaction": {
15954 /// "type": [
15955 /// "object",
15956 /// "null"
15957 /// ],
15958 /// "properties": {
15959 /// "guid": {
15960 /// "examples": [
15961 /// "RPT-065b8b1d-826a-45ce-8487-60ca1510e72a"
15962 /// ],
15963 /// "type": "string"
15964 /// },
15965 /// "recurrence_type": {
15966 /// "type": "string",
15967 /// "enum": [
15968 /// "EVERY_OTHER_WEEK"
15969 /// ]
15970 /// },
15971 /// "repeating_transaction_type": {
15972 /// "type": "string",
15973 /// "enum": [
15974 /// "BILL",
15975 /// "SUBSCRIPTION",
15976 /// "INCOME",
15977 /// "UNKNOWN"
15978 /// ]
15979 /// }
15980 /// }
15981 /// }
15982 /// }
15983 /// }
15984 /// ]
15985 ///}
15986 /// ```
15987 /// </details>
15988 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
15989 pub struct TransactionIncludesResponse {
15990 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
15991 pub account_guid: ::std::option::Option<::std::string::String>,
15992 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
15993 pub account_id: ::std::option::Option<::std::string::String>,
15994 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
15995 pub amount: ::std::option::Option<f64>,
15996 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
15997 pub category: ::std::option::Option<::std::string::String>,
15998 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
15999 pub category_guid: ::std::option::Option<::std::string::String>,
16000 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
16001 pub check_number_string: ::std::option::Option<::std::string::String>,
16002 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
16003 pub classification: ::std::option::Option<TransactionIncludesResponseClassification>,
16004 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
16005 pub created_at: ::std::option::Option<::std::string::String>,
16006 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
16007 pub currency_code: ::std::option::Option<::std::string::String>,
16008 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
16009 pub date: ::std::option::Option<::std::string::String>,
16010 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
16011 pub description: ::std::option::Option<::std::string::String>,
16012 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
16013 pub extended_transaction_type: ::std::option::Option<::std::string::String>,
16014 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
16015 pub geolocation: ::std::option::Option<TransactionIncludesResponseGeolocation>,
16016 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
16017 pub guid: ::std::option::Option<::std::string::String>,
16018 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
16019 pub id: ::std::option::Option<::std::string::String>,
16020 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
16021 pub is_bill_pay: ::std::option::Option<bool>,
16022 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
16023 pub is_direct_deposit: ::std::option::Option<bool>,
16024 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
16025 pub is_expense: ::std::option::Option<bool>,
16026 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
16027 pub is_fee: ::std::option::Option<bool>,
16028 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
16029 pub is_income: ::std::option::Option<bool>,
16030 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
16031 pub is_international: ::std::option::Option<bool>,
16032 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
16033 pub is_manual: ::std::option::Option<bool>,
16034 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
16035 pub is_overdraft_fee: ::std::option::Option<bool>,
16036 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
16037 pub is_payroll_advance: ::std::option::Option<bool>,
16038 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
16039 pub is_recurring: ::std::option::Option<bool>,
16040 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
16041 pub is_subscription: ::std::option::Option<bool>,
16042 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
16043 pub latitude: ::std::option::Option<f64>,
16044 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
16045 pub localized_description: ::std::option::Option<::std::string::String>,
16046 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
16047 pub localized_memo: ::std::option::Option<::std::string::String>,
16048 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
16049 pub longitude: ::std::option::Option<f64>,
16050 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
16051 pub member_guid: ::std::option::Option<::std::string::String>,
16052 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
16053 pub member_is_managed_by_user: ::std::option::Option<bool>,
16054 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
16055 pub memo: ::std::option::Option<::std::string::String>,
16056 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
16057 pub merchant: ::std::option::Option<TransactionIncludesResponseMerchant>,
16058 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
16059 pub merchant_category_code: ::std::option::Option<i64>,
16060 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
16061 pub merchant_guid: ::std::option::Option<::std::string::String>,
16062 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
16063 pub merchant_location_guid: ::std::option::Option<::std::string::String>,
16064 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
16065 pub metadata: ::std::option::Option<::std::string::String>,
16066 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
16067 pub original_description: ::std::option::Option<::std::string::String>,
16068 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
16069 pub posted_at: ::std::option::Option<::std::string::String>,
16070 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
16071 pub repeating_transaction:
16072 ::std::option::Option<TransactionIncludesResponseRepeatingTransaction>,
16073 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
16074 pub status: ::std::option::Option<::std::string::String>,
16075 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
16076 pub top_level_category: ::std::option::Option<::std::string::String>,
16077 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
16078 pub transacted_at: ::std::option::Option<::std::string::String>,
16079 #[serde(
16080 rename = "type",
16081 default,
16082 skip_serializing_if = "::std::option::Option::is_none"
16083 )]
16084 pub type_: ::std::option::Option<::std::string::String>,
16085 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
16086 pub updated_at: ::std::option::Option<::std::string::String>,
16087 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
16088 pub user_guid: ::std::option::Option<::std::string::String>,
16089 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
16090 pub user_id: ::std::option::Option<::std::string::String>,
16091 }
16092
16093 impl ::std::convert::From<&TransactionIncludesResponse> for TransactionIncludesResponse {
16094 fn from(value: &TransactionIncludesResponse) -> Self {
16095 value.clone()
16096 }
16097 }
16098
16099 impl ::std::default::Default for TransactionIncludesResponse {
16100 fn default() -> Self {
16101 Self {
16102 account_guid: Default::default(),
16103 account_id: Default::default(),
16104 amount: Default::default(),
16105 category: Default::default(),
16106 category_guid: Default::default(),
16107 check_number_string: Default::default(),
16108 classification: Default::default(),
16109 created_at: Default::default(),
16110 currency_code: Default::default(),
16111 date: Default::default(),
16112 description: Default::default(),
16113 extended_transaction_type: Default::default(),
16114 geolocation: Default::default(),
16115 guid: Default::default(),
16116 id: Default::default(),
16117 is_bill_pay: Default::default(),
16118 is_direct_deposit: Default::default(),
16119 is_expense: Default::default(),
16120 is_fee: Default::default(),
16121 is_income: Default::default(),
16122 is_international: Default::default(),
16123 is_manual: Default::default(),
16124 is_overdraft_fee: Default::default(),
16125 is_payroll_advance: Default::default(),
16126 is_recurring: Default::default(),
16127 is_subscription: Default::default(),
16128 latitude: Default::default(),
16129 localized_description: Default::default(),
16130 localized_memo: Default::default(),
16131 longitude: Default::default(),
16132 member_guid: Default::default(),
16133 member_is_managed_by_user: Default::default(),
16134 memo: Default::default(),
16135 merchant: Default::default(),
16136 merchant_category_code: Default::default(),
16137 merchant_guid: Default::default(),
16138 merchant_location_guid: Default::default(),
16139 metadata: Default::default(),
16140 original_description: Default::default(),
16141 posted_at: Default::default(),
16142 repeating_transaction: Default::default(),
16143 status: Default::default(),
16144 top_level_category: Default::default(),
16145 transacted_at: Default::default(),
16146 type_: Default::default(),
16147 updated_at: Default::default(),
16148 user_guid: Default::default(),
16149 user_id: Default::default(),
16150 }
16151 }
16152 }
16153
16154 ///`TransactionIncludesResponseClassification`
16155 ///
16156 /// <details><summary>JSON schema</summary>
16157 ///
16158 /// ```json
16159 ///{
16160 /// "type": "object",
16161 /// "properties": {
16162 /// "guid": {
16163 /// "examples": [
16164 /// "MNC-3ad50f86-60d0-4545-a1f9-e66c2ac40f69"
16165 /// ],
16166 /// "type": "string"
16167 /// },
16168 /// "parent_class": {
16169 /// "examples": [
16170 /// "Deposit"
16171 /// ],
16172 /// "type": "string",
16173 /// "enum": [
16174 /// "Payroll",
16175 /// "Deposit",
16176 /// "Savings",
16177 /// "Transfer",
16178 /// "Refunds",
16179 /// "Spend",
16180 /// "Investment",
16181 /// "Buy",
16182 /// "Sell",
16183 /// "Income",
16184 /// "Fees",
16185 /// "Expenses",
16186 /// "Corporate Actions",
16187 /// "Other"
16188 /// ]
16189 /// }
16190 /// }
16191 ///}
16192 /// ```
16193 /// </details>
16194 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
16195 pub struct TransactionIncludesResponseClassification {
16196 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
16197 pub guid: ::std::option::Option<::std::string::String>,
16198 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
16199 pub parent_class:
16200 ::std::option::Option<TransactionIncludesResponseClassificationParentClass>,
16201 }
16202
16203 impl ::std::convert::From<&TransactionIncludesResponseClassification>
16204 for TransactionIncludesResponseClassification
16205 {
16206 fn from(value: &TransactionIncludesResponseClassification) -> Self {
16207 value.clone()
16208 }
16209 }
16210
16211 impl ::std::default::Default for TransactionIncludesResponseClassification {
16212 fn default() -> Self {
16213 Self {
16214 guid: Default::default(),
16215 parent_class: Default::default(),
16216 }
16217 }
16218 }
16219
16220 ///`TransactionIncludesResponseClassificationParentClass`
16221 ///
16222 /// <details><summary>JSON schema</summary>
16223 ///
16224 /// ```json
16225 ///{
16226 /// "examples": [
16227 /// "Deposit"
16228 /// ],
16229 /// "type": "string",
16230 /// "enum": [
16231 /// "Payroll",
16232 /// "Deposit",
16233 /// "Savings",
16234 /// "Transfer",
16235 /// "Refunds",
16236 /// "Spend",
16237 /// "Investment",
16238 /// "Buy",
16239 /// "Sell",
16240 /// "Income",
16241 /// "Fees",
16242 /// "Expenses",
16243 /// "Corporate Actions",
16244 /// "Other"
16245 /// ]
16246 ///}
16247 /// ```
16248 /// </details>
16249 #[derive(
16250 :: serde :: Deserialize,
16251 :: serde :: Serialize,
16252 Clone,
16253 Copy,
16254 Debug,
16255 Eq,
16256 Hash,
16257 Ord,
16258 PartialEq,
16259 PartialOrd,
16260 )]
16261 pub enum TransactionIncludesResponseClassificationParentClass {
16262 Payroll,
16263 Deposit,
16264 Savings,
16265 Transfer,
16266 Refunds,
16267 Spend,
16268 Investment,
16269 Buy,
16270 Sell,
16271 Income,
16272 Fees,
16273 Expenses,
16274 #[serde(rename = "Corporate Actions")]
16275 CorporateActions,
16276 Other,
16277 }
16278
16279 impl ::std::convert::From<&Self> for TransactionIncludesResponseClassificationParentClass {
16280 fn from(value: &TransactionIncludesResponseClassificationParentClass) -> Self {
16281 value.clone()
16282 }
16283 }
16284
16285 impl ::std::fmt::Display for TransactionIncludesResponseClassificationParentClass {
16286 fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
16287 match *self {
16288 Self::Payroll => f.write_str("Payroll"),
16289 Self::Deposit => f.write_str("Deposit"),
16290 Self::Savings => f.write_str("Savings"),
16291 Self::Transfer => f.write_str("Transfer"),
16292 Self::Refunds => f.write_str("Refunds"),
16293 Self::Spend => f.write_str("Spend"),
16294 Self::Investment => f.write_str("Investment"),
16295 Self::Buy => f.write_str("Buy"),
16296 Self::Sell => f.write_str("Sell"),
16297 Self::Income => f.write_str("Income"),
16298 Self::Fees => f.write_str("Fees"),
16299 Self::Expenses => f.write_str("Expenses"),
16300 Self::CorporateActions => f.write_str("Corporate Actions"),
16301 Self::Other => f.write_str("Other"),
16302 }
16303 }
16304 }
16305
16306 impl ::std::str::FromStr for TransactionIncludesResponseClassificationParentClass {
16307 type Err = self::error::ConversionError;
16308 fn from_str(value: &str) -> ::std::result::Result<Self, self::error::ConversionError> {
16309 match value {
16310 "Payroll" => Ok(Self::Payroll),
16311 "Deposit" => Ok(Self::Deposit),
16312 "Savings" => Ok(Self::Savings),
16313 "Transfer" => Ok(Self::Transfer),
16314 "Refunds" => Ok(Self::Refunds),
16315 "Spend" => Ok(Self::Spend),
16316 "Investment" => Ok(Self::Investment),
16317 "Buy" => Ok(Self::Buy),
16318 "Sell" => Ok(Self::Sell),
16319 "Income" => Ok(Self::Income),
16320 "Fees" => Ok(Self::Fees),
16321 "Expenses" => Ok(Self::Expenses),
16322 "Corporate Actions" => Ok(Self::CorporateActions),
16323 "Other" => Ok(Self::Other),
16324 _ => Err("invalid value".into()),
16325 }
16326 }
16327 }
16328
16329 impl ::std::convert::TryFrom<&str> for TransactionIncludesResponseClassificationParentClass {
16330 type Error = self::error::ConversionError;
16331 fn try_from(value: &str) -> ::std::result::Result<Self, self::error::ConversionError> {
16332 value.parse()
16333 }
16334 }
16335
16336 impl ::std::convert::TryFrom<&::std::string::String>
16337 for TransactionIncludesResponseClassificationParentClass
16338 {
16339 type Error = self::error::ConversionError;
16340 fn try_from(
16341 value: &::std::string::String,
16342 ) -> ::std::result::Result<Self, self::error::ConversionError> {
16343 value.parse()
16344 }
16345 }
16346
16347 impl ::std::convert::TryFrom<::std::string::String>
16348 for TransactionIncludesResponseClassificationParentClass
16349 {
16350 type Error = self::error::ConversionError;
16351 fn try_from(
16352 value: ::std::string::String,
16353 ) -> ::std::result::Result<Self, self::error::ConversionError> {
16354 value.parse()
16355 }
16356 }
16357
16358 ///`TransactionIncludesResponseGeolocation`
16359 ///
16360 /// <details><summary>JSON schema</summary>
16361 ///
16362 /// ```json
16363 ///{
16364 /// "type": "object",
16365 /// "properties": {
16366 /// "city": {
16367 /// "examples": [
16368 /// "lehi"
16369 /// ],
16370 /// "type": "string"
16371 /// },
16372 /// "country": {
16373 /// "examples": [
16374 /// "us"
16375 /// ],
16376 /// "type": "string"
16377 /// },
16378 /// "postal code": {
16379 /// "examples": [
16380 /// "84043"
16381 /// ],
16382 /// "type": "string"
16383 /// },
16384 /// "state": {
16385 /// "examples": [
16386 /// "UT"
16387 /// ],
16388 /// "type": "string"
16389 /// }
16390 /// }
16391 ///}
16392 /// ```
16393 /// </details>
16394 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
16395 pub struct TransactionIncludesResponseGeolocation {
16396 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
16397 pub city: ::std::option::Option<::std::string::String>,
16398 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
16399 pub country: ::std::option::Option<::std::string::String>,
16400 #[serde(
16401 rename = "postal code",
16402 default,
16403 skip_serializing_if = "::std::option::Option::is_none"
16404 )]
16405 pub postal_code: ::std::option::Option<::std::string::String>,
16406 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
16407 pub state: ::std::option::Option<::std::string::String>,
16408 }
16409
16410 impl ::std::convert::From<&TransactionIncludesResponseGeolocation>
16411 for TransactionIncludesResponseGeolocation
16412 {
16413 fn from(value: &TransactionIncludesResponseGeolocation) -> Self {
16414 value.clone()
16415 }
16416 }
16417
16418 impl ::std::default::Default for TransactionIncludesResponseGeolocation {
16419 fn default() -> Self {
16420 Self {
16421 city: Default::default(),
16422 country: Default::default(),
16423 postal_code: Default::default(),
16424 state: Default::default(),
16425 }
16426 }
16427 }
16428
16429 ///`TransactionIncludesResponseMerchant`
16430 ///
16431 /// <details><summary>JSON schema</summary>
16432 ///
16433 /// ```json
16434 ///{
16435 /// "type": "object",
16436 /// "properties": {
16437 /// "guid": {
16438 /// "examples": [
16439 /// "MCH-0c25f895-393c-42a4-9c18-95a0b26d4d84"
16440 /// ],
16441 /// "type": "string"
16442 /// },
16443 /// "logo_url": {
16444 /// "examples": [
16445 /// "https://content.mx.com/logos/merchants/MCH-0c25f895-393c-42a4-9c18-95a0b26d4d84.png"
16446 /// ],
16447 /// "type": "string"
16448 /// },
16449 /// "name": {
16450 /// "examples": [
16451 /// "MX"
16452 /// ],
16453 /// "type": "string"
16454 /// },
16455 /// "website_url": {
16456 /// "examples": [
16457 /// "https://www.mx.com"
16458 /// ],
16459 /// "type": "string"
16460 /// }
16461 /// }
16462 ///}
16463 /// ```
16464 /// </details>
16465 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
16466 pub struct TransactionIncludesResponseMerchant {
16467 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
16468 pub guid: ::std::option::Option<::std::string::String>,
16469 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
16470 pub logo_url: ::std::option::Option<::std::string::String>,
16471 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
16472 pub name: ::std::option::Option<::std::string::String>,
16473 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
16474 pub website_url: ::std::option::Option<::std::string::String>,
16475 }
16476
16477 impl ::std::convert::From<&TransactionIncludesResponseMerchant>
16478 for TransactionIncludesResponseMerchant
16479 {
16480 fn from(value: &TransactionIncludesResponseMerchant) -> Self {
16481 value.clone()
16482 }
16483 }
16484
16485 impl ::std::default::Default for TransactionIncludesResponseMerchant {
16486 fn default() -> Self {
16487 Self {
16488 guid: Default::default(),
16489 logo_url: Default::default(),
16490 name: Default::default(),
16491 website_url: Default::default(),
16492 }
16493 }
16494 }
16495
16496 ///`TransactionIncludesResponseRepeatingTransaction`
16497 ///
16498 /// <details><summary>JSON schema</summary>
16499 ///
16500 /// ```json
16501 ///{
16502 /// "type": "object",
16503 /// "properties": {
16504 /// "guid": {
16505 /// "examples": [
16506 /// "RPT-065b8b1d-826a-45ce-8487-60ca1510e72a"
16507 /// ],
16508 /// "type": "string"
16509 /// },
16510 /// "recurrence_type": {
16511 /// "type": "string",
16512 /// "enum": [
16513 /// "EVERY_OTHER_WEEK"
16514 /// ]
16515 /// },
16516 /// "repeating_transaction_type": {
16517 /// "type": "string",
16518 /// "enum": [
16519 /// "BILL",
16520 /// "SUBSCRIPTION",
16521 /// "INCOME",
16522 /// "UNKNOWN"
16523 /// ]
16524 /// }
16525 /// }
16526 ///}
16527 /// ```
16528 /// </details>
16529 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
16530 pub struct TransactionIncludesResponseRepeatingTransaction {
16531 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
16532 pub guid: ::std::option::Option<::std::string::String>,
16533 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
16534 pub recurrence_type:
16535 ::std::option::Option<TransactionIncludesResponseRepeatingTransactionRecurrenceType>,
16536 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
16537 pub repeating_transaction_type: ::std::option::Option<
16538 TransactionIncludesResponseRepeatingTransactionRepeatingTransactionType,
16539 >,
16540 }
16541
16542 impl ::std::convert::From<&TransactionIncludesResponseRepeatingTransaction>
16543 for TransactionIncludesResponseRepeatingTransaction
16544 {
16545 fn from(value: &TransactionIncludesResponseRepeatingTransaction) -> Self {
16546 value.clone()
16547 }
16548 }
16549
16550 impl ::std::default::Default for TransactionIncludesResponseRepeatingTransaction {
16551 fn default() -> Self {
16552 Self {
16553 guid: Default::default(),
16554 recurrence_type: Default::default(),
16555 repeating_transaction_type: Default::default(),
16556 }
16557 }
16558 }
16559
16560 ///`TransactionIncludesResponseRepeatingTransactionRecurrenceType`
16561 ///
16562 /// <details><summary>JSON schema</summary>
16563 ///
16564 /// ```json
16565 ///{
16566 /// "type": "string",
16567 /// "enum": [
16568 /// "EVERY_OTHER_WEEK"
16569 /// ]
16570 ///}
16571 /// ```
16572 /// </details>
16573 #[derive(
16574 :: serde :: Deserialize,
16575 :: serde :: Serialize,
16576 Clone,
16577 Copy,
16578 Debug,
16579 Eq,
16580 Hash,
16581 Ord,
16582 PartialEq,
16583 PartialOrd,
16584 )]
16585 pub enum TransactionIncludesResponseRepeatingTransactionRecurrenceType {
16586 #[serde(rename = "EVERY_OTHER_WEEK")]
16587 EveryOtherWeek,
16588 }
16589
16590 impl ::std::convert::From<&Self> for TransactionIncludesResponseRepeatingTransactionRecurrenceType {
16591 fn from(value: &TransactionIncludesResponseRepeatingTransactionRecurrenceType) -> Self {
16592 value.clone()
16593 }
16594 }
16595
16596 impl ::std::fmt::Display for TransactionIncludesResponseRepeatingTransactionRecurrenceType {
16597 fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
16598 match *self {
16599 Self::EveryOtherWeek => f.write_str("EVERY_OTHER_WEEK"),
16600 }
16601 }
16602 }
16603
16604 impl ::std::str::FromStr for TransactionIncludesResponseRepeatingTransactionRecurrenceType {
16605 type Err = self::error::ConversionError;
16606 fn from_str(value: &str) -> ::std::result::Result<Self, self::error::ConversionError> {
16607 match value {
16608 "EVERY_OTHER_WEEK" => Ok(Self::EveryOtherWeek),
16609 _ => Err("invalid value".into()),
16610 }
16611 }
16612 }
16613
16614 impl ::std::convert::TryFrom<&str>
16615 for TransactionIncludesResponseRepeatingTransactionRecurrenceType
16616 {
16617 type Error = self::error::ConversionError;
16618 fn try_from(value: &str) -> ::std::result::Result<Self, self::error::ConversionError> {
16619 value.parse()
16620 }
16621 }
16622
16623 impl ::std::convert::TryFrom<&::std::string::String>
16624 for TransactionIncludesResponseRepeatingTransactionRecurrenceType
16625 {
16626 type Error = self::error::ConversionError;
16627 fn try_from(
16628 value: &::std::string::String,
16629 ) -> ::std::result::Result<Self, self::error::ConversionError> {
16630 value.parse()
16631 }
16632 }
16633
16634 impl ::std::convert::TryFrom<::std::string::String>
16635 for TransactionIncludesResponseRepeatingTransactionRecurrenceType
16636 {
16637 type Error = self::error::ConversionError;
16638 fn try_from(
16639 value: ::std::string::String,
16640 ) -> ::std::result::Result<Self, self::error::ConversionError> {
16641 value.parse()
16642 }
16643 }
16644
16645 ///`TransactionIncludesResponseRepeatingTransactionRepeatingTransactionType`
16646 ///
16647 /// <details><summary>JSON schema</summary>
16648 ///
16649 /// ```json
16650 ///{
16651 /// "type": "string",
16652 /// "enum": [
16653 /// "BILL",
16654 /// "SUBSCRIPTION",
16655 /// "INCOME",
16656 /// "UNKNOWN"
16657 /// ]
16658 ///}
16659 /// ```
16660 /// </details>
16661 #[derive(
16662 :: serde :: Deserialize,
16663 :: serde :: Serialize,
16664 Clone,
16665 Copy,
16666 Debug,
16667 Eq,
16668 Hash,
16669 Ord,
16670 PartialEq,
16671 PartialOrd,
16672 )]
16673 pub enum TransactionIncludesResponseRepeatingTransactionRepeatingTransactionType {
16674 #[serde(rename = "BILL")]
16675 Bill,
16676 #[serde(rename = "SUBSCRIPTION")]
16677 Subscription,
16678 #[serde(rename = "INCOME")]
16679 Income,
16680 #[serde(rename = "UNKNOWN")]
16681 Unknown,
16682 }
16683
16684 impl ::std::convert::From<&Self>
16685 for TransactionIncludesResponseRepeatingTransactionRepeatingTransactionType
16686 {
16687 fn from(
16688 value: &TransactionIncludesResponseRepeatingTransactionRepeatingTransactionType,
16689 ) -> Self {
16690 value.clone()
16691 }
16692 }
16693
16694 impl ::std::fmt::Display
16695 for TransactionIncludesResponseRepeatingTransactionRepeatingTransactionType
16696 {
16697 fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
16698 match *self {
16699 Self::Bill => f.write_str("BILL"),
16700 Self::Subscription => f.write_str("SUBSCRIPTION"),
16701 Self::Income => f.write_str("INCOME"),
16702 Self::Unknown => f.write_str("UNKNOWN"),
16703 }
16704 }
16705 }
16706
16707 impl ::std::str::FromStr
16708 for TransactionIncludesResponseRepeatingTransactionRepeatingTransactionType
16709 {
16710 type Err = self::error::ConversionError;
16711 fn from_str(value: &str) -> ::std::result::Result<Self, self::error::ConversionError> {
16712 match value {
16713 "BILL" => Ok(Self::Bill),
16714 "SUBSCRIPTION" => Ok(Self::Subscription),
16715 "INCOME" => Ok(Self::Income),
16716 "UNKNOWN" => Ok(Self::Unknown),
16717 _ => Err("invalid value".into()),
16718 }
16719 }
16720 }
16721
16722 impl ::std::convert::TryFrom<&str>
16723 for TransactionIncludesResponseRepeatingTransactionRepeatingTransactionType
16724 {
16725 type Error = self::error::ConversionError;
16726 fn try_from(value: &str) -> ::std::result::Result<Self, self::error::ConversionError> {
16727 value.parse()
16728 }
16729 }
16730
16731 impl ::std::convert::TryFrom<&::std::string::String>
16732 for TransactionIncludesResponseRepeatingTransactionRepeatingTransactionType
16733 {
16734 type Error = self::error::ConversionError;
16735 fn try_from(
16736 value: &::std::string::String,
16737 ) -> ::std::result::Result<Self, self::error::ConversionError> {
16738 value.parse()
16739 }
16740 }
16741
16742 impl ::std::convert::TryFrom<::std::string::String>
16743 for TransactionIncludesResponseRepeatingTransactionRepeatingTransactionType
16744 {
16745 type Error = self::error::ConversionError;
16746 fn try_from(
16747 value: ::std::string::String,
16748 ) -> ::std::result::Result<Self, self::error::ConversionError> {
16749 value.parse()
16750 }
16751 }
16752
16753 ///`TransactionResponse`
16754 ///
16755 /// <details><summary>JSON schema</summary>
16756 ///
16757 /// ```json
16758 ///{
16759 /// "type": "object",
16760 /// "properties": {
16761 /// "account_guid": {
16762 /// "examples": [
16763 /// "ACT-0af29528-bb91-447f-b5de-85c1c42593e5"
16764 /// ],
16765 /// "type": [
16766 /// "string",
16767 /// "null"
16768 /// ]
16769 /// },
16770 /// "account_id": {
16771 /// "examples": [
16772 /// "FdvkkAgLS0nbDNUujrblz6rYDSl5w-tTLwYRgIxe7jw"
16773 /// ],
16774 /// "type": [
16775 /// "string",
16776 /// "null"
16777 /// ]
16778 /// },
16779 /// "amount": {
16780 /// "examples": [
16781 /// 5003.9
16782 /// ],
16783 /// "type": [
16784 /// "number",
16785 /// "null"
16786 /// ]
16787 /// },
16788 /// "category": {
16789 /// "examples": [
16790 /// "Paycheck"
16791 /// ],
16792 /// "type": [
16793 /// "string",
16794 /// "null"
16795 /// ]
16796 /// },
16797 /// "category_guid": {
16798 /// "examples": [
16799 /// "CAT-982ea9e6-3f0e-0c5b-611b-6657a10ba819"
16800 /// ],
16801 /// "type": [
16802 /// "string",
16803 /// "null"
16804 /// ]
16805 /// },
16806 /// "check_number_string": {
16807 /// "type": [
16808 /// "string",
16809 /// "null"
16810 /// ]
16811 /// },
16812 /// "created_at": {
16813 /// "examples": [
16814 /// "2024-12-20T18:52:36Z"
16815 /// ],
16816 /// "type": [
16817 /// "string",
16818 /// "null"
16819 /// ]
16820 /// },
16821 /// "currency_code": {
16822 /// "type": [
16823 /// "string",
16824 /// "null"
16825 /// ]
16826 /// },
16827 /// "date": {
16828 /// "examples": [
16829 /// "2024-12-20"
16830 /// ],
16831 /// "type": [
16832 /// "string",
16833 /// "null"
16834 /// ]
16835 /// },
16836 /// "description": {
16837 /// "examples": [
16838 /// "MX Technologies"
16839 /// ],
16840 /// "type": [
16841 /// "string",
16842 /// "null"
16843 /// ]
16844 /// },
16845 /// "extended_transaction_type": {
16846 /// "type": [
16847 /// "string",
16848 /// "null"
16849 /// ]
16850 /// },
16851 /// "guid": {
16852 /// "examples": [
16853 /// "TRN-429ad9fe-a1d2-4559-8590-885b2603f0e1"
16854 /// ],
16855 /// "type": [
16856 /// "string",
16857 /// "null"
16858 /// ]
16859 /// },
16860 /// "id": {
16861 /// "examples": [
16862 /// "1734681600000-178fa8095c154a55b9172f977b4c5f9a-0"
16863 /// ],
16864 /// "type": [
16865 /// "string",
16866 /// "null"
16867 /// ]
16868 /// },
16869 /// "is_bill_pay": {
16870 /// "examples": [
16871 /// false
16872 /// ],
16873 /// "type": [
16874 /// "boolean",
16875 /// "null"
16876 /// ]
16877 /// },
16878 /// "is_direct_deposit": {
16879 /// "examples": [
16880 /// false
16881 /// ],
16882 /// "type": [
16883 /// "boolean",
16884 /// "null"
16885 /// ]
16886 /// },
16887 /// "is_expense": {
16888 /// "examples": [
16889 /// false
16890 /// ],
16891 /// "type": [
16892 /// "boolean",
16893 /// "null"
16894 /// ]
16895 /// },
16896 /// "is_fee": {
16897 /// "examples": [
16898 /// false
16899 /// ],
16900 /// "type": [
16901 /// "boolean",
16902 /// "null"
16903 /// ]
16904 /// },
16905 /// "is_income": {
16906 /// "examples": [
16907 /// true
16908 /// ],
16909 /// "type": [
16910 /// "boolean",
16911 /// "null"
16912 /// ]
16913 /// },
16914 /// "is_international": {
16915 /// "type": [
16916 /// "boolean",
16917 /// "null"
16918 /// ]
16919 /// },
16920 /// "is_manual": {
16921 /// "examples": [
16922 /// false
16923 /// ],
16924 /// "type": [
16925 /// "boolean",
16926 /// "null"
16927 /// ]
16928 /// },
16929 /// "is_overdraft_fee": {
16930 /// "examples": [
16931 /// false
16932 /// ],
16933 /// "type": [
16934 /// "boolean",
16935 /// "null"
16936 /// ]
16937 /// },
16938 /// "is_payroll_advance": {
16939 /// "examples": [
16940 /// false
16941 /// ],
16942 /// "type": [
16943 /// "boolean",
16944 /// "null"
16945 /// ]
16946 /// },
16947 /// "is_recurring": {
16948 /// "type": [
16949 /// "boolean",
16950 /// "null"
16951 /// ]
16952 /// },
16953 /// "is_subscription": {
16954 /// "examples": [
16955 /// false
16956 /// ],
16957 /// "type": [
16958 /// "boolean",
16959 /// "null"
16960 /// ]
16961 /// },
16962 /// "latitude": {
16963 /// "type": [
16964 /// "number",
16965 /// "null"
16966 /// ]
16967 /// },
16968 /// "localized_description": {
16969 /// "type": [
16970 /// "string",
16971 /// "null"
16972 /// ]
16973 /// },
16974 /// "localized_memo": {
16975 /// "type": [
16976 /// "string",
16977 /// "null"
16978 /// ]
16979 /// },
16980 /// "longitude": {
16981 /// "type": [
16982 /// "number",
16983 /// "null"
16984 /// ]
16985 /// },
16986 /// "member_guid": {
16987 /// "examples": [
16988 /// "MBR-78b14c5f-7297-4fb5-a966-65ac45f74d8"
16989 /// ],
16990 /// "type": [
16991 /// "string",
16992 /// "null"
16993 /// ]
16994 /// },
16995 /// "member_is_managed_by_user": {
16996 /// "examples": [
16997 /// true
16998 /// ],
16999 /// "type": [
17000 /// "boolean",
17001 /// "null"
17002 /// ]
17003 /// },
17004 /// "memo": {
17005 /// "examples": [
17006 /// "Transactions"
17007 /// ],
17008 /// "type": [
17009 /// "string",
17010 /// "null"
17011 /// ]
17012 /// },
17013 /// "merchant_category_code": {
17014 /// "type": [
17015 /// "integer",
17016 /// "null"
17017 /// ]
17018 /// },
17019 /// "merchant_guid": {
17020 /// "examples": [
17021 /// "MCH-8cc3b01a-1c52-47d4-970d-30f8ee5566f1"
17022 /// ],
17023 /// "type": [
17024 /// "string",
17025 /// "null"
17026 /// ]
17027 /// },
17028 /// "merchant_location_guid": {
17029 /// "type": [
17030 /// "string",
17031 /// "null"
17032 /// ]
17033 /// },
17034 /// "metadata": {
17035 /// "type": [
17036 /// "string",
17037 /// "null"
17038 /// ]
17039 /// },
17040 /// "original_description": {
17041 /// "examples": [
17042 /// "MX TECHNOLOGIES PAYMENT"
17043 /// ],
17044 /// "type": [
17045 /// "string",
17046 /// "null"
17047 /// ]
17048 /// },
17049 /// "posted_at": {
17050 /// "examples": [
17051 /// "2024-12-20T12:00:00Z"
17052 /// ],
17053 /// "type": [
17054 /// "string",
17055 /// "null"
17056 /// ]
17057 /// },
17058 /// "status": {
17059 /// "examples": [
17060 /// "POSTED"
17061 /// ],
17062 /// "type": [
17063 /// "string",
17064 /// "null"
17065 /// ]
17066 /// },
17067 /// "top_level_category": {
17068 /// "examples": [
17069 /// "Income"
17070 /// ],
17071 /// "type": [
17072 /// "string",
17073 /// "null"
17074 /// ]
17075 /// },
17076 /// "transacted_at": {
17077 /// "examples": [
17078 /// "2024-12-20T12:00:00Z"
17079 /// ],
17080 /// "type": [
17081 /// "string",
17082 /// "null"
17083 /// ]
17084 /// },
17085 /// "type": {
17086 /// "examples": [
17087 /// "CREDIT"
17088 /// ],
17089 /// "type": [
17090 /// "string",
17091 /// "null"
17092 /// ]
17093 /// },
17094 /// "updated_at": {
17095 /// "examples": [
17096 /// "2024-12-20T18:52:38Z"
17097 /// ],
17098 /// "type": [
17099 /// "string",
17100 /// "null"
17101 /// ]
17102 /// },
17103 /// "user_guid": {
17104 /// "examples": [
17105 /// "USR-ef7a82f6-d6c1-42c4-9061-bdece5c4d44e"
17106 /// ],
17107 /// "type": [
17108 /// "string",
17109 /// "null"
17110 /// ]
17111 /// },
17112 /// "user_id": {
17113 /// "type": [
17114 /// "string",
17115 /// "null"
17116 /// ]
17117 /// }
17118 /// }
17119 ///}
17120 /// ```
17121 /// </details>
17122 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
17123 pub struct TransactionResponse {
17124 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17125 pub account_guid: ::std::option::Option<::std::string::String>,
17126 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17127 pub account_id: ::std::option::Option<::std::string::String>,
17128 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17129 pub amount: ::std::option::Option<f64>,
17130 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17131 pub category: ::std::option::Option<::std::string::String>,
17132 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17133 pub category_guid: ::std::option::Option<::std::string::String>,
17134 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17135 pub check_number_string: ::std::option::Option<::std::string::String>,
17136 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17137 pub created_at: ::std::option::Option<::std::string::String>,
17138 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17139 pub currency_code: ::std::option::Option<::std::string::String>,
17140 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17141 pub date: ::std::option::Option<::std::string::String>,
17142 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17143 pub description: ::std::option::Option<::std::string::String>,
17144 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17145 pub extended_transaction_type: ::std::option::Option<::std::string::String>,
17146 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17147 pub guid: ::std::option::Option<::std::string::String>,
17148 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17149 pub id: ::std::option::Option<::std::string::String>,
17150 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17151 pub is_bill_pay: ::std::option::Option<bool>,
17152 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17153 pub is_direct_deposit: ::std::option::Option<bool>,
17154 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17155 pub is_expense: ::std::option::Option<bool>,
17156 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17157 pub is_fee: ::std::option::Option<bool>,
17158 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17159 pub is_income: ::std::option::Option<bool>,
17160 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17161 pub is_international: ::std::option::Option<bool>,
17162 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17163 pub is_manual: ::std::option::Option<bool>,
17164 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17165 pub is_overdraft_fee: ::std::option::Option<bool>,
17166 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17167 pub is_payroll_advance: ::std::option::Option<bool>,
17168 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17169 pub is_recurring: ::std::option::Option<bool>,
17170 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17171 pub is_subscription: ::std::option::Option<bool>,
17172 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17173 pub latitude: ::std::option::Option<f64>,
17174 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17175 pub localized_description: ::std::option::Option<::std::string::String>,
17176 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17177 pub localized_memo: ::std::option::Option<::std::string::String>,
17178 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17179 pub longitude: ::std::option::Option<f64>,
17180 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17181 pub member_guid: ::std::option::Option<::std::string::String>,
17182 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17183 pub member_is_managed_by_user: ::std::option::Option<bool>,
17184 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17185 pub memo: ::std::option::Option<::std::string::String>,
17186 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17187 pub merchant_category_code: ::std::option::Option<i64>,
17188 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17189 pub merchant_guid: ::std::option::Option<::std::string::String>,
17190 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17191 pub merchant_location_guid: ::std::option::Option<::std::string::String>,
17192 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17193 pub metadata: ::std::option::Option<::std::string::String>,
17194 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17195 pub original_description: ::std::option::Option<::std::string::String>,
17196 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17197 pub posted_at: ::std::option::Option<::std::string::String>,
17198 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17199 pub status: ::std::option::Option<::std::string::String>,
17200 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17201 pub top_level_category: ::std::option::Option<::std::string::String>,
17202 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17203 pub transacted_at: ::std::option::Option<::std::string::String>,
17204 #[serde(
17205 rename = "type",
17206 default,
17207 skip_serializing_if = "::std::option::Option::is_none"
17208 )]
17209 pub type_: ::std::option::Option<::std::string::String>,
17210 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17211 pub updated_at: ::std::option::Option<::std::string::String>,
17212 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17213 pub user_guid: ::std::option::Option<::std::string::String>,
17214 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17215 pub user_id: ::std::option::Option<::std::string::String>,
17216 }
17217
17218 impl ::std::convert::From<&TransactionResponse> for TransactionResponse {
17219 fn from(value: &TransactionResponse) -> Self {
17220 value.clone()
17221 }
17222 }
17223
17224 impl ::std::default::Default for TransactionResponse {
17225 fn default() -> Self {
17226 Self {
17227 account_guid: Default::default(),
17228 account_id: Default::default(),
17229 amount: Default::default(),
17230 category: Default::default(),
17231 category_guid: Default::default(),
17232 check_number_string: Default::default(),
17233 created_at: Default::default(),
17234 currency_code: Default::default(),
17235 date: Default::default(),
17236 description: Default::default(),
17237 extended_transaction_type: Default::default(),
17238 guid: Default::default(),
17239 id: Default::default(),
17240 is_bill_pay: Default::default(),
17241 is_direct_deposit: Default::default(),
17242 is_expense: Default::default(),
17243 is_fee: Default::default(),
17244 is_income: Default::default(),
17245 is_international: Default::default(),
17246 is_manual: Default::default(),
17247 is_overdraft_fee: Default::default(),
17248 is_payroll_advance: Default::default(),
17249 is_recurring: Default::default(),
17250 is_subscription: Default::default(),
17251 latitude: Default::default(),
17252 localized_description: Default::default(),
17253 localized_memo: Default::default(),
17254 longitude: Default::default(),
17255 member_guid: Default::default(),
17256 member_is_managed_by_user: Default::default(),
17257 memo: Default::default(),
17258 merchant_category_code: Default::default(),
17259 merchant_guid: Default::default(),
17260 merchant_location_guid: Default::default(),
17261 metadata: Default::default(),
17262 original_description: Default::default(),
17263 posted_at: Default::default(),
17264 status: Default::default(),
17265 top_level_category: Default::default(),
17266 transacted_at: Default::default(),
17267 type_: Default::default(),
17268 updated_at: Default::default(),
17269 user_guid: Default::default(),
17270 user_id: Default::default(),
17271 }
17272 }
17273 }
17274
17275 ///`TransactionResponseBody`
17276 ///
17277 /// <details><summary>JSON schema</summary>
17278 ///
17279 /// ```json
17280 ///{
17281 /// "type": "object",
17282 /// "properties": {
17283 /// "transaction": {
17284 /// "$ref": "#/components/schemas/TransactionResponse"
17285 /// }
17286 /// }
17287 ///}
17288 /// ```
17289 /// </details>
17290 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
17291 pub struct TransactionResponseBody {
17292 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17293 pub transaction: ::std::option::Option<TransactionResponse>,
17294 }
17295
17296 impl ::std::convert::From<&TransactionResponseBody> for TransactionResponseBody {
17297 fn from(value: &TransactionResponseBody) -> Self {
17298 value.clone()
17299 }
17300 }
17301
17302 impl ::std::default::Default for TransactionResponseBody {
17303 fn default() -> Self {
17304 Self {
17305 transaction: Default::default(),
17306 }
17307 }
17308 }
17309
17310 ///`TransactionRuleCreateRequest`
17311 ///
17312 /// <details><summary>JSON schema</summary>
17313 ///
17314 /// ```json
17315 ///{
17316 /// "type": "object",
17317 /// "required": [
17318 /// "category_guid",
17319 /// "match_description"
17320 /// ],
17321 /// "properties": {
17322 /// "category_guid": {
17323 /// "examples": [
17324 /// "CAT-b1de2a04-db08-b6ed-f6fe-ca2f5b11c2d0"
17325 /// ],
17326 /// "type": "string"
17327 /// },
17328 /// "description": {
17329 /// "examples": [
17330 /// "Wal-mart food storage"
17331 /// ],
17332 /// "type": "string"
17333 /// },
17334 /// "match_description": {
17335 /// "examples": [
17336 /// "Wal-mart"
17337 /// ],
17338 /// "type": "string"
17339 /// }
17340 /// }
17341 ///}
17342 /// ```
17343 /// </details>
17344 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
17345 pub struct TransactionRuleCreateRequest {
17346 pub category_guid: ::std::string::String,
17347 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17348 pub description: ::std::option::Option<::std::string::String>,
17349 pub match_description: ::std::string::String,
17350 }
17351
17352 impl ::std::convert::From<&TransactionRuleCreateRequest> for TransactionRuleCreateRequest {
17353 fn from(value: &TransactionRuleCreateRequest) -> Self {
17354 value.clone()
17355 }
17356 }
17357
17358 ///`TransactionRuleCreateRequestBody`
17359 ///
17360 /// <details><summary>JSON schema</summary>
17361 ///
17362 /// ```json
17363 ///{
17364 /// "type": "object",
17365 /// "properties": {
17366 /// "transaction_rule": {
17367 /// "$ref": "#/components/schemas/TransactionRuleCreateRequest"
17368 /// }
17369 /// }
17370 ///}
17371 /// ```
17372 /// </details>
17373 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
17374 pub struct TransactionRuleCreateRequestBody {
17375 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17376 pub transaction_rule: ::std::option::Option<TransactionRuleCreateRequest>,
17377 }
17378
17379 impl ::std::convert::From<&TransactionRuleCreateRequestBody> for TransactionRuleCreateRequestBody {
17380 fn from(value: &TransactionRuleCreateRequestBody) -> Self {
17381 value.clone()
17382 }
17383 }
17384
17385 impl ::std::default::Default for TransactionRuleCreateRequestBody {
17386 fn default() -> Self {
17387 Self {
17388 transaction_rule: Default::default(),
17389 }
17390 }
17391 }
17392
17393 ///`TransactionRuleResponse`
17394 ///
17395 /// <details><summary>JSON schema</summary>
17396 ///
17397 /// ```json
17398 ///{
17399 /// "type": "object",
17400 /// "properties": {
17401 /// "category_guid": {
17402 /// "examples": [
17403 /// "CAT-b1de2a04-db08-b6ed-f6fe-ca2f5b11c2d0"
17404 /// ],
17405 /// "type": [
17406 /// "string",
17407 /// "null"
17408 /// ]
17409 /// },
17410 /// "created_at": {
17411 /// "examples": [
17412 /// "2018-10-02T22:00:50+00:00"
17413 /// ],
17414 /// "type": [
17415 /// "string",
17416 /// "null"
17417 /// ]
17418 /// },
17419 /// "description": {
17420 /// "examples": [
17421 /// "Wal-mart food storage"
17422 /// ],
17423 /// "type": [
17424 /// "string",
17425 /// "null"
17426 /// ]
17427 /// },
17428 /// "guid": {
17429 /// "examples": [
17430 /// "TXR-a080e0f9-a2d4-4d6f-9e03-672cc357a4d3"
17431 /// ],
17432 /// "type": [
17433 /// "string",
17434 /// "null"
17435 /// ]
17436 /// },
17437 /// "match_description": {
17438 /// "examples": [
17439 /// "Wal-mart"
17440 /// ],
17441 /// "type": [
17442 /// "string",
17443 /// "null"
17444 /// ]
17445 /// },
17446 /// "updated_at": {
17447 /// "examples": [
17448 /// "2018-10-02T23:54:40+00:00"
17449 /// ],
17450 /// "type": [
17451 /// "string",
17452 /// "null"
17453 /// ]
17454 /// },
17455 /// "user_guid": {
17456 /// "examples": [
17457 /// "USR-22fc3203-b3e6-8340-43db-8e50b2f56995"
17458 /// ],
17459 /// "type": [
17460 /// "string",
17461 /// "null"
17462 /// ]
17463 /// }
17464 /// }
17465 ///}
17466 /// ```
17467 /// </details>
17468 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
17469 pub struct TransactionRuleResponse {
17470 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17471 pub category_guid: ::std::option::Option<::std::string::String>,
17472 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17473 pub created_at: ::std::option::Option<::std::string::String>,
17474 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17475 pub description: ::std::option::Option<::std::string::String>,
17476 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17477 pub guid: ::std::option::Option<::std::string::String>,
17478 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17479 pub match_description: ::std::option::Option<::std::string::String>,
17480 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17481 pub updated_at: ::std::option::Option<::std::string::String>,
17482 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17483 pub user_guid: ::std::option::Option<::std::string::String>,
17484 }
17485
17486 impl ::std::convert::From<&TransactionRuleResponse> for TransactionRuleResponse {
17487 fn from(value: &TransactionRuleResponse) -> Self {
17488 value.clone()
17489 }
17490 }
17491
17492 impl ::std::default::Default for TransactionRuleResponse {
17493 fn default() -> Self {
17494 Self {
17495 category_guid: Default::default(),
17496 created_at: Default::default(),
17497 description: Default::default(),
17498 guid: Default::default(),
17499 match_description: Default::default(),
17500 updated_at: Default::default(),
17501 user_guid: Default::default(),
17502 }
17503 }
17504 }
17505
17506 ///`TransactionRuleResponseBody`
17507 ///
17508 /// <details><summary>JSON schema</summary>
17509 ///
17510 /// ```json
17511 ///{
17512 /// "type": "object",
17513 /// "properties": {
17514 /// "transaction_rule": {
17515 /// "$ref": "#/components/schemas/TransactionRuleResponse"
17516 /// }
17517 /// }
17518 ///}
17519 /// ```
17520 /// </details>
17521 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
17522 pub struct TransactionRuleResponseBody {
17523 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17524 pub transaction_rule: ::std::option::Option<TransactionRuleResponse>,
17525 }
17526
17527 impl ::std::convert::From<&TransactionRuleResponseBody> for TransactionRuleResponseBody {
17528 fn from(value: &TransactionRuleResponseBody) -> Self {
17529 value.clone()
17530 }
17531 }
17532
17533 impl ::std::default::Default for TransactionRuleResponseBody {
17534 fn default() -> Self {
17535 Self {
17536 transaction_rule: Default::default(),
17537 }
17538 }
17539 }
17540
17541 ///`TransactionRuleUpdateRequest`
17542 ///
17543 /// <details><summary>JSON schema</summary>
17544 ///
17545 /// ```json
17546 ///{
17547 /// "type": "object",
17548 /// "properties": {
17549 /// "category_guid": {
17550 /// "examples": [
17551 /// "CAT-b1de2a04-db08-b6ed-f6fe-ca2f5b11c2d0"
17552 /// ],
17553 /// "type": "string"
17554 /// },
17555 /// "description": {
17556 /// "examples": [
17557 /// "Wal-mart food storage"
17558 /// ],
17559 /// "type": "string"
17560 /// },
17561 /// "match_description": {
17562 /// "examples": [
17563 /// "Wal-mart"
17564 /// ],
17565 /// "type": "string"
17566 /// }
17567 /// }
17568 ///}
17569 /// ```
17570 /// </details>
17571 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
17572 pub struct TransactionRuleUpdateRequest {
17573 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17574 pub category_guid: ::std::option::Option<::std::string::String>,
17575 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17576 pub description: ::std::option::Option<::std::string::String>,
17577 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17578 pub match_description: ::std::option::Option<::std::string::String>,
17579 }
17580
17581 impl ::std::convert::From<&TransactionRuleUpdateRequest> for TransactionRuleUpdateRequest {
17582 fn from(value: &TransactionRuleUpdateRequest) -> Self {
17583 value.clone()
17584 }
17585 }
17586
17587 impl ::std::default::Default for TransactionRuleUpdateRequest {
17588 fn default() -> Self {
17589 Self {
17590 category_guid: Default::default(),
17591 description: Default::default(),
17592 match_description: Default::default(),
17593 }
17594 }
17595 }
17596
17597 ///`TransactionRuleUpdateRequestBody`
17598 ///
17599 /// <details><summary>JSON schema</summary>
17600 ///
17601 /// ```json
17602 ///{
17603 /// "type": "object",
17604 /// "properties": {
17605 /// "transaction_rule": {
17606 /// "$ref": "#/components/schemas/TransactionRuleUpdateRequest"
17607 /// }
17608 /// }
17609 ///}
17610 /// ```
17611 /// </details>
17612 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
17613 pub struct TransactionRuleUpdateRequestBody {
17614 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17615 pub transaction_rule: ::std::option::Option<TransactionRuleUpdateRequest>,
17616 }
17617
17618 impl ::std::convert::From<&TransactionRuleUpdateRequestBody> for TransactionRuleUpdateRequestBody {
17619 fn from(value: &TransactionRuleUpdateRequestBody) -> Self {
17620 value.clone()
17621 }
17622 }
17623
17624 impl ::std::default::Default for TransactionRuleUpdateRequestBody {
17625 fn default() -> Self {
17626 Self {
17627 transaction_rule: Default::default(),
17628 }
17629 }
17630 }
17631
17632 ///`TransactionRulesResponseBody`
17633 ///
17634 /// <details><summary>JSON schema</summary>
17635 ///
17636 /// ```json
17637 ///{
17638 /// "type": "object",
17639 /// "properties": {
17640 /// "pagination": {
17641 /// "$ref": "#/components/schemas/PaginationResponse"
17642 /// },
17643 /// "transaction_rules": {
17644 /// "type": "array",
17645 /// "items": {
17646 /// "$ref": "#/components/schemas/TransactionRuleResponse"
17647 /// }
17648 /// }
17649 /// }
17650 ///}
17651 /// ```
17652 /// </details>
17653 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
17654 pub struct TransactionRulesResponseBody {
17655 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17656 pub pagination: ::std::option::Option<PaginationResponse>,
17657 #[serde(default, skip_serializing_if = "::std::vec::Vec::is_empty")]
17658 pub transaction_rules: ::std::vec::Vec<TransactionRuleResponse>,
17659 }
17660
17661 impl ::std::convert::From<&TransactionRulesResponseBody> for TransactionRulesResponseBody {
17662 fn from(value: &TransactionRulesResponseBody) -> Self {
17663 value.clone()
17664 }
17665 }
17666
17667 impl ::std::default::Default for TransactionRulesResponseBody {
17668 fn default() -> Self {
17669 Self {
17670 pagination: Default::default(),
17671 transaction_rules: Default::default(),
17672 }
17673 }
17674 }
17675
17676 ///`TransactionUpdateRequest`
17677 ///
17678 /// <details><summary>JSON schema</summary>
17679 ///
17680 /// ```json
17681 ///{
17682 /// "type": "object",
17683 /// "properties": {
17684 /// "category_guid": {
17685 /// "type": "string"
17686 /// },
17687 /// "date": {
17688 /// "type": "string"
17689 /// },
17690 /// "description": {
17691 /// "examples": [
17692 /// "new description"
17693 /// ],
17694 /// "type": "string"
17695 /// },
17696 /// "memo": {
17697 /// "type": "string"
17698 /// }
17699 /// }
17700 ///}
17701 /// ```
17702 /// </details>
17703 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
17704 pub struct TransactionUpdateRequest {
17705 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17706 pub category_guid: ::std::option::Option<::std::string::String>,
17707 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17708 pub date: ::std::option::Option<::std::string::String>,
17709 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17710 pub description: ::std::option::Option<::std::string::String>,
17711 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17712 pub memo: ::std::option::Option<::std::string::String>,
17713 }
17714
17715 impl ::std::convert::From<&TransactionUpdateRequest> for TransactionUpdateRequest {
17716 fn from(value: &TransactionUpdateRequest) -> Self {
17717 value.clone()
17718 }
17719 }
17720
17721 impl ::std::default::Default for TransactionUpdateRequest {
17722 fn default() -> Self {
17723 Self {
17724 category_guid: Default::default(),
17725 date: Default::default(),
17726 description: Default::default(),
17727 memo: Default::default(),
17728 }
17729 }
17730 }
17731
17732 ///`TransactionUpdateRequestBody`
17733 ///
17734 /// <details><summary>JSON schema</summary>
17735 ///
17736 /// ```json
17737 ///{
17738 /// "type": "object",
17739 /// "properties": {
17740 /// "transaction": {
17741 /// "$ref": "#/components/schemas/TransactionUpdateRequest"
17742 /// }
17743 /// }
17744 ///}
17745 /// ```
17746 /// </details>
17747 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
17748 pub struct TransactionUpdateRequestBody {
17749 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17750 pub transaction: ::std::option::Option<TransactionUpdateRequest>,
17751 }
17752
17753 impl ::std::convert::From<&TransactionUpdateRequestBody> for TransactionUpdateRequestBody {
17754 fn from(value: &TransactionUpdateRequestBody) -> Self {
17755 value.clone()
17756 }
17757 }
17758
17759 impl ::std::default::Default for TransactionUpdateRequestBody {
17760 fn default() -> Self {
17761 Self {
17762 transaction: Default::default(),
17763 }
17764 }
17765 }
17766
17767 ///`TransactionsResponseBody`
17768 ///
17769 /// <details><summary>JSON schema</summary>
17770 ///
17771 /// ```json
17772 ///{
17773 /// "properties": {
17774 /// "pagination": {
17775 /// "$ref": "#/components/schemas/PaginationResponse"
17776 /// },
17777 /// "transactions": {
17778 /// "type": "array",
17779 /// "items": {
17780 /// "$ref": "#/components/schemas/TransactionResponse"
17781 /// }
17782 /// }
17783 /// }
17784 ///}
17785 /// ```
17786 /// </details>
17787 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
17788 pub struct TransactionsResponseBody {
17789 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17790 pub pagination: ::std::option::Option<PaginationResponse>,
17791 #[serde(default, skip_serializing_if = "::std::vec::Vec::is_empty")]
17792 pub transactions: ::std::vec::Vec<TransactionResponse>,
17793 }
17794
17795 impl ::std::convert::From<&TransactionsResponseBody> for TransactionsResponseBody {
17796 fn from(value: &TransactionsResponseBody) -> Self {
17797 value.clone()
17798 }
17799 }
17800
17801 impl ::std::default::Default for TransactionsResponseBody {
17802 fn default() -> Self {
17803 Self {
17804 pagination: Default::default(),
17805 transactions: Default::default(),
17806 }
17807 }
17808 }
17809
17810 ///`TransactionsResponseBodyIncludes`
17811 ///
17812 /// <details><summary>JSON schema</summary>
17813 ///
17814 /// ```json
17815 ///{
17816 /// "type": "object",
17817 /// "properties": {
17818 /// "pagination": {
17819 /// "$ref": "#/components/schemas/PaginationResponse"
17820 /// },
17821 /// "transactions": {
17822 /// "type": "array",
17823 /// "items": {
17824 /// "$ref": "#/components/schemas/TransactionIncludesResponse"
17825 /// }
17826 /// }
17827 /// }
17828 ///}
17829 /// ```
17830 /// </details>
17831 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
17832 pub struct TransactionsResponseBodyIncludes {
17833 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17834 pub pagination: ::std::option::Option<PaginationResponse>,
17835 #[serde(default, skip_serializing_if = "::std::vec::Vec::is_empty")]
17836 pub transactions: ::std::vec::Vec<TransactionIncludesResponse>,
17837 }
17838
17839 impl ::std::convert::From<&TransactionsResponseBodyIncludes> for TransactionsResponseBodyIncludes {
17840 fn from(value: &TransactionsResponseBodyIncludes) -> Self {
17841 value.clone()
17842 }
17843 }
17844
17845 impl ::std::default::Default for TransactionsResponseBodyIncludes {
17846 fn default() -> Self {
17847 Self {
17848 pagination: Default::default(),
17849 transactions: Default::default(),
17850 }
17851 }
17852 }
17853
17854 ///`UpdateGoalRequest`
17855 ///
17856 /// <details><summary>JSON schema</summary>
17857 ///
17858 /// ```json
17859 ///{
17860 /// "type": "object",
17861 /// "properties": {
17862 /// "account_guid": {
17863 /// "description": "Unique identifier of the account for the goal.",
17864 /// "examples": [
17865 /// "ACT-4e431124-4a29-abf9-f059-ab232ac14dbf"
17866 /// ],
17867 /// "type": "string"
17868 /// },
17869 /// "amount": {
17870 /// "description": "Amount of the goal.",
17871 /// "examples": [
17872 /// 4500.5
17873 /// ],
17874 /// "type": "number"
17875 /// },
17876 /// "completed_at": {
17877 /// "description": "Date and time the goal was completed.",
17878 /// "examples": [
17879 /// "2015-06-19T10:37:04-06:00"
17880 /// ],
17881 /// "type": "string"
17882 /// },
17883 /// "goal_type_name": {
17884 /// "description": "The goal type.",
17885 /// "examples": [
17886 /// "PAYOFF"
17887 /// ],
17888 /// "type": "string"
17889 /// },
17890 /// "has_been_spent": {
17891 /// "description": "Determines if the goal has been spent.",
17892 /// "examples": [
17893 /// false
17894 /// ],
17895 /// "type": "boolean"
17896 /// },
17897 /// "is_complete": {
17898 /// "description": "Determines if the goal is complete.",
17899 /// "examples": [
17900 /// false
17901 /// ],
17902 /// "type": "boolean"
17903 /// },
17904 /// "meta_type_name": {
17905 /// "description": "The category of the goal.",
17906 /// "examples": [
17907 /// "VACATION"
17908 /// ],
17909 /// "type": "string"
17910 /// },
17911 /// "metadata": {
17912 /// "description": "Additional information a partner can store on the
17913 /// goal.",
17914 /// "examples": [
17915 /// "Additional information"
17916 /// ],
17917 /// "type": "string"
17918 /// },
17919 /// "name": {
17920 /// "description": "The name of the goal.",
17921 /// "examples": [
17922 /// "Save for Europe"
17923 /// ],
17924 /// "type": "string"
17925 /// },
17926 /// "position": {
17927 /// "description": "The priority of the goal in relation to multiple
17928 /// goals.",
17929 /// "examples": [
17930 /// 3
17931 /// ],
17932 /// "type": "integer"
17933 /// },
17934 /// "targeted_to_complete_at": {
17935 /// "description": "Date and time the goal is to complete. Intended for
17936 /// users to set their own goal completion dates.",
17937 /// "examples": [
17938 /// "2026-12-08 00:00:00.000000"
17939 /// ],
17940 /// "type": "string"
17941 /// }
17942 /// }
17943 ///}
17944 /// ```
17945 /// </details>
17946 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
17947 pub struct UpdateGoalRequest {
17948 ///Unique identifier of the account for the goal.
17949 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17950 pub account_guid: ::std::option::Option<::std::string::String>,
17951 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17952 pub amount: ::std::option::Option<f64>,
17953 ///Date and time the goal was completed.
17954 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17955 pub completed_at: ::std::option::Option<::std::string::String>,
17956 ///The goal type.
17957 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17958 pub goal_type_name: ::std::option::Option<::std::string::String>,
17959 ///Determines if the goal has been spent.
17960 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17961 pub has_been_spent: ::std::option::Option<bool>,
17962 ///Determines if the goal is complete.
17963 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17964 pub is_complete: ::std::option::Option<bool>,
17965 ///The category of the goal.
17966 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17967 pub meta_type_name: ::std::option::Option<::std::string::String>,
17968 ///Additional information a partner can store on the goal.
17969 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17970 pub metadata: ::std::option::Option<::std::string::String>,
17971 ///The name of the goal.
17972 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17973 pub name: ::std::option::Option<::std::string::String>,
17974 ///The priority of the goal in relation to multiple goals.
17975 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17976 pub position: ::std::option::Option<i64>,
17977 ///Date and time the goal is to complete. Intended for users to set
17978 /// their own goal completion dates.
17979 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
17980 pub targeted_to_complete_at: ::std::option::Option<::std::string::String>,
17981 }
17982
17983 impl ::std::convert::From<&UpdateGoalRequest> for UpdateGoalRequest {
17984 fn from(value: &UpdateGoalRequest) -> Self {
17985 value.clone()
17986 }
17987 }
17988
17989 impl ::std::default::Default for UpdateGoalRequest {
17990 fn default() -> Self {
17991 Self {
17992 account_guid: Default::default(),
17993 amount: Default::default(),
17994 completed_at: Default::default(),
17995 goal_type_name: Default::default(),
17996 has_been_spent: Default::default(),
17997 is_complete: Default::default(),
17998 meta_type_name: Default::default(),
17999 metadata: Default::default(),
18000 name: Default::default(),
18001 position: Default::default(),
18002 targeted_to_complete_at: Default::default(),
18003 }
18004 }
18005 }
18006
18007 ///`UpdateGoalRequestBody`
18008 ///
18009 /// <details><summary>JSON schema</summary>
18010 ///
18011 /// ```json
18012 ///{
18013 /// "type": "object",
18014 /// "properties": {
18015 /// "goal": {
18016 /// "$ref": "#/components/schemas/UpdateGoalRequest"
18017 /// }
18018 /// }
18019 ///}
18020 /// ```
18021 /// </details>
18022 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
18023 pub struct UpdateGoalRequestBody {
18024 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
18025 pub goal: ::std::option::Option<UpdateGoalRequest>,
18026 }
18027
18028 impl ::std::convert::From<&UpdateGoalRequestBody> for UpdateGoalRequestBody {
18029 fn from(value: &UpdateGoalRequestBody) -> Self {
18030 value.clone()
18031 }
18032 }
18033
18034 impl ::std::default::Default for UpdateGoalRequestBody {
18035 fn default() -> Self {
18036 Self {
18037 goal: Default::default(),
18038 }
18039 }
18040 }
18041
18042 ///`UserCreateRequest`
18043 ///
18044 /// <details><summary>JSON schema</summary>
18045 ///
18046 /// ```json
18047 ///{
18048 /// "type": "object",
18049 /// "properties": {
18050 /// "email": {
18051 /// "examples": [
18052 /// "email@provider.com"
18053 /// ],
18054 /// "type": "string"
18055 /// },
18056 /// "id": {
18057 /// "examples": [
18058 /// "My-Unique-ID"
18059 /// ],
18060 /// "type": "string"
18061 /// },
18062 /// "is_disabled": {
18063 /// "examples": [
18064 /// false
18065 /// ],
18066 /// "type": "boolean"
18067 /// },
18068 /// "metadata": {
18069 /// "examples": [
18070 /// "{\\\"type\\\": \\\"individual\\\", \\\"status\\\":
18071 /// \\\"preferred\\\"}"
18072 /// ],
18073 /// "type": "string"
18074 /// }
18075 /// }
18076 ///}
18077 /// ```
18078 /// </details>
18079 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
18080 pub struct UserCreateRequest {
18081 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
18082 pub email: ::std::option::Option<::std::string::String>,
18083 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
18084 pub id: ::std::option::Option<::std::string::String>,
18085 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
18086 pub is_disabled: ::std::option::Option<bool>,
18087 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
18088 pub metadata: ::std::option::Option<::std::string::String>,
18089 }
18090
18091 impl ::std::convert::From<&UserCreateRequest> for UserCreateRequest {
18092 fn from(value: &UserCreateRequest) -> Self {
18093 value.clone()
18094 }
18095 }
18096
18097 impl ::std::default::Default for UserCreateRequest {
18098 fn default() -> Self {
18099 Self {
18100 email: Default::default(),
18101 id: Default::default(),
18102 is_disabled: Default::default(),
18103 metadata: Default::default(),
18104 }
18105 }
18106 }
18107
18108 ///`UserCreateRequestBody`
18109 ///
18110 /// <details><summary>JSON schema</summary>
18111 ///
18112 /// ```json
18113 ///{
18114 /// "type": "object",
18115 /// "properties": {
18116 /// "user": {
18117 /// "$ref": "#/components/schemas/UserCreateRequest"
18118 /// }
18119 /// }
18120 ///}
18121 /// ```
18122 /// </details>
18123 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
18124 pub struct UserCreateRequestBody {
18125 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
18126 pub user: ::std::option::Option<UserCreateRequest>,
18127 }
18128
18129 impl ::std::convert::From<&UserCreateRequestBody> for UserCreateRequestBody {
18130 fn from(value: &UserCreateRequestBody) -> Self {
18131 value.clone()
18132 }
18133 }
18134
18135 impl ::std::default::Default for UserCreateRequestBody {
18136 fn default() -> Self {
18137 Self {
18138 user: Default::default(),
18139 }
18140 }
18141 }
18142
18143 ///`UserResponse`
18144 ///
18145 /// <details><summary>JSON schema</summary>
18146 ///
18147 /// ```json
18148 ///{
18149 /// "type": "object",
18150 /// "properties": {
18151 /// "email": {
18152 /// "examples": [
18153 /// "email@provider.com"
18154 /// ],
18155 /// "type": [
18156 /// "string",
18157 /// "null"
18158 /// ]
18159 /// },
18160 /// "guid": {
18161 /// "examples": [
18162 /// "USR-d74cb14f-fd0a-449f-991b-e0362a63d9c6"
18163 /// ],
18164 /// "type": [
18165 /// "string",
18166 /// "null"
18167 /// ]
18168 /// },
18169 /// "id": {
18170 /// "examples": [
18171 /// "My-Unique-ID"
18172 /// ],
18173 /// "type": [
18174 /// "string",
18175 /// "null"
18176 /// ]
18177 /// },
18178 /// "is_disabled": {
18179 /// "examples": [
18180 /// false
18181 /// ],
18182 /// "type": [
18183 /// "boolean",
18184 /// "null"
18185 /// ]
18186 /// },
18187 /// "metadata": {
18188 /// "examples": [
18189 /// "{\\\"first_name\\\": \\\"Steven\\\", \\\"last_name\\\":
18190 /// \\\"Universe\\\"}"
18191 /// ],
18192 /// "type": [
18193 /// "string",
18194 /// "null"
18195 /// ]
18196 /// }
18197 /// }
18198 ///}
18199 /// ```
18200 /// </details>
18201 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
18202 pub struct UserResponse {
18203 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
18204 pub email: ::std::option::Option<::std::string::String>,
18205 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
18206 pub guid: ::std::option::Option<::std::string::String>,
18207 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
18208 pub id: ::std::option::Option<::std::string::String>,
18209 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
18210 pub is_disabled: ::std::option::Option<bool>,
18211 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
18212 pub metadata: ::std::option::Option<::std::string::String>,
18213 }
18214
18215 impl ::std::convert::From<&UserResponse> for UserResponse {
18216 fn from(value: &UserResponse) -> Self {
18217 value.clone()
18218 }
18219 }
18220
18221 impl ::std::default::Default for UserResponse {
18222 fn default() -> Self {
18223 Self {
18224 email: Default::default(),
18225 guid: Default::default(),
18226 id: Default::default(),
18227 is_disabled: Default::default(),
18228 metadata: Default::default(),
18229 }
18230 }
18231 }
18232
18233 ///`UserResponseBody`
18234 ///
18235 /// <details><summary>JSON schema</summary>
18236 ///
18237 /// ```json
18238 ///{
18239 /// "type": "object",
18240 /// "properties": {
18241 /// "user": {
18242 /// "$ref": "#/components/schemas/UserResponse"
18243 /// }
18244 /// }
18245 ///}
18246 /// ```
18247 /// </details>
18248 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
18249 pub struct UserResponseBody {
18250 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
18251 pub user: ::std::option::Option<UserResponse>,
18252 }
18253
18254 impl ::std::convert::From<&UserResponseBody> for UserResponseBody {
18255 fn from(value: &UserResponseBody) -> Self {
18256 value.clone()
18257 }
18258 }
18259
18260 impl ::std::default::Default for UserResponseBody {
18261 fn default() -> Self {
18262 Self {
18263 user: Default::default(),
18264 }
18265 }
18266 }
18267
18268 ///`UserUpdateRequest`
18269 ///
18270 /// <details><summary>JSON schema</summary>
18271 ///
18272 /// ```json
18273 ///{
18274 /// "type": "object",
18275 /// "properties": {
18276 /// "email": {
18277 /// "examples": [
18278 /// "email@provider.com"
18279 /// ],
18280 /// "type": "string"
18281 /// },
18282 /// "id": {
18283 /// "examples": [
18284 /// "My-Unique-ID"
18285 /// ],
18286 /// "type": "string"
18287 /// },
18288 /// "is_disabled": {
18289 /// "examples": [
18290 /// false
18291 /// ],
18292 /// "type": "boolean"
18293 /// },
18294 /// "metadata": {
18295 /// "examples": [
18296 /// "{\\\"first_name\\\": \\\"Steven\\\", \\\"last_name\\\":
18297 /// \\\"Universe\\\"}"
18298 /// ],
18299 /// "type": "string"
18300 /// }
18301 /// }
18302 ///}
18303 /// ```
18304 /// </details>
18305 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
18306 pub struct UserUpdateRequest {
18307 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
18308 pub email: ::std::option::Option<::std::string::String>,
18309 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
18310 pub id: ::std::option::Option<::std::string::String>,
18311 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
18312 pub is_disabled: ::std::option::Option<bool>,
18313 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
18314 pub metadata: ::std::option::Option<::std::string::String>,
18315 }
18316
18317 impl ::std::convert::From<&UserUpdateRequest> for UserUpdateRequest {
18318 fn from(value: &UserUpdateRequest) -> Self {
18319 value.clone()
18320 }
18321 }
18322
18323 impl ::std::default::Default for UserUpdateRequest {
18324 fn default() -> Self {
18325 Self {
18326 email: Default::default(),
18327 id: Default::default(),
18328 is_disabled: Default::default(),
18329 metadata: Default::default(),
18330 }
18331 }
18332 }
18333
18334 ///`UserUpdateRequestBody`
18335 ///
18336 /// <details><summary>JSON schema</summary>
18337 ///
18338 /// ```json
18339 ///{
18340 /// "type": "object",
18341 /// "properties": {
18342 /// "user": {
18343 /// "$ref": "#/components/schemas/UserUpdateRequest"
18344 /// }
18345 /// }
18346 ///}
18347 /// ```
18348 /// </details>
18349 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
18350 pub struct UserUpdateRequestBody {
18351 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
18352 pub user: ::std::option::Option<UserUpdateRequest>,
18353 }
18354
18355 impl ::std::convert::From<&UserUpdateRequestBody> for UserUpdateRequestBody {
18356 fn from(value: &UserUpdateRequestBody) -> Self {
18357 value.clone()
18358 }
18359 }
18360
18361 impl ::std::default::Default for UserUpdateRequestBody {
18362 fn default() -> Self {
18363 Self {
18364 user: Default::default(),
18365 }
18366 }
18367 }
18368
18369 ///`UsersResponseBody`
18370 ///
18371 /// <details><summary>JSON schema</summary>
18372 ///
18373 /// ```json
18374 ///{
18375 /// "type": "object",
18376 /// "properties": {
18377 /// "pagination": {
18378 /// "$ref": "#/components/schemas/PaginationResponse"
18379 /// },
18380 /// "users": {
18381 /// "type": "array",
18382 /// "items": {
18383 /// "$ref": "#/components/schemas/UserResponse"
18384 /// }
18385 /// }
18386 /// }
18387 ///}
18388 /// ```
18389 /// </details>
18390 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
18391 pub struct UsersResponseBody {
18392 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
18393 pub pagination: ::std::option::Option<PaginationResponse>,
18394 #[serde(default, skip_serializing_if = "::std::vec::Vec::is_empty")]
18395 pub users: ::std::vec::Vec<UserResponse>,
18396 }
18397
18398 impl ::std::convert::From<&UsersResponseBody> for UsersResponseBody {
18399 fn from(value: &UsersResponseBody) -> Self {
18400 value.clone()
18401 }
18402 }
18403
18404 impl ::std::default::Default for UsersResponseBody {
18405 fn default() -> Self {
18406 Self {
18407 pagination: Default::default(),
18408 users: Default::default(),
18409 }
18410 }
18411 }
18412
18413 ///`VcResponse`
18414 ///
18415 /// <details><summary>JSON schema</summary>
18416 ///
18417 /// ```json
18418 ///{
18419 /// "type": "object",
18420 /// "properties": {
18421 /// "verifiableCredential": {
18422 /// "examples": [
18423 /// "feJgbGciOiJFZERTQSEsImtpFCI6ImRpZDpksHR6c4E6MTNkdzdqeWc0NGVqd2NkZjhpcWNzZWg3amN6NTF3ajZmanhib29qNDFpcGVnNzZlbyMwIiwidHlwIjoiSldUIn0.eyJ2YyI6eyJAY29udGV4dCI6WyJodHRwczovL3d3dy53My5vcmcvMjAxOC9jcmVkZW50aWFscy92MSJdLCJpZCI6Imh0dHBzOi8vYXBpLnNhbmQuaW50ZXJuYWwubXgvdmMvdXNlcnMvVVNSLTNlYTdjYzMxLWVkZDYtNDQxNy05YjM1LWRlZTZlMjQ4NDI1Yi9tZW1iZXJzL01CUi1jYzUxNDViZi02M2Q5LTQ5OGYtODc3Mi1lNGVmMzI0MWNjYjYvYWNjb3VudHMiLCJ0eXBlIjpbIlZlcmlmaWFibGVDcmVkZW50aWFsIiwiRmluYW5jaWFsQWNjb3VudENyZWRlbnRpYWwiXSwiaXNzdWVyIjoiZGlkOmRodDpzYTcxM2R3N2p5ZzQ0ZWp3Y2RmOGlxY3NlaDdqY3o1MXdqNmZqeGJvb2o0MWlwZWc3NmVvIiwiaXNzdWFuY2VEYXRlIjoiMjAyNC0wMy0wMVQxODo0MjoxOVoiLCJjcmVkZW50aWFsU3ViamVjdCI6eyJhY2NvdW50cyI6W3sibG9jQWNjb3VudCI6eyJhY2NvdW52SWQiOeABQ1RtODRhMDEyNjgtNTdkMC00YTI4LWEwYzEtZTcyYWRyNDA5NbJkIiwiYWNjb3VudFR5cFUiOiJDUkVESVRDQVJEIiwiYWNjb3VudE51bWJlciI6IjM0OTcyNTM0NCIsImFjY291bnROdW1iZXJEaXNwbGF5IjoiKioqKjUzNDQiLCJwcm9kdWN0TmFtZSI6bnVsbCwibmlja25hbWUiOm51bGwsInN0YXR1cyI6Ik9QRU4iLCJhY2NvdW50T3BlbkRhdGUiOiIyMDIyLTA3LTExVDE1OjQwOjQwWiIsImFjY291bnRDbG9zZWREYXRlIjpudWxsLCJjdXJyZW5jeSI6eyJjdXJyZW5jeVJhdGUiOm51bGwsImN1cnJlbmN5Q29kZSI6bnVsbCwib3JpZ2luYWxDdXJyZW5jeUNvZGUiOm51bGx9LCJmaUF0dHJpYnV0ZXMiOlt7Im5hbWUiOiJtZW1iZXJfZ3VpZCIsInZhbHVlIjoiTUJSLWNjNTE0NWJmLTYzZDktNDk4Zi04NzcyLWU0ZWYzMjQxY2NiNiJ9LHsibmFtZSI6Imluc3RpdHV0aW9uX2d1aWQiLCJ2YWx1ZSI6IklOUy1mMWEzMjg1ZC1lODU1LWI2OGYtNmFhNy04YWU3NzVjMGUwZTkifSx7Im5hbWUiOiJleHRlcm5hbF9ndWlkIiwidmFsdWUiOiJhY2NvdW50LWY3ZTg3ZWZmLTA2YzAtNDZhMS1iODAwLTUxOTI3ODM2MjFhOSJ9XSwicm91dGluZ1RyYW5zaXROdW1iZXIiOm51bGwsImJhbGFuY2VUeXBlIjoiTElBQklMSVRZIiwiaW50ZXJlc3RSYXRlIjpudWxsLCJsYXN0QWN0aXZpdHlEYXRlIjoiMjAyMi0wNy0xMVQxNTo0MDo0MFoiLCJiYWxhbmNlQXNPZiI6IjIwMjItMDctMTFUMTU6NDA6NDBaIiwiY3JlZGl0TGluZSI6bnVsbCwiYXZhaWxhYmxlQ3JlZGl0IjoxMzAwMC4wLCJuZXh0UGF5bWVudERhdGUiOm51bGwsInByaW5jaXBhbEJhbGFuY2UiOm51bGwsImN1cnJlbnRCYWxhbmNlIjoxMDAwLjAsIm1pbmltdW1QYXltZW50QW1vdW50IjpudWxsLCJwdXJjaGFzZXNBcHIiOm51bGx9fSx7ImRlcG9zaXRBY2NvdW50Ijp7ImFjY291bnRJZCI6IkFDVC05NmYzMGQ2Ny0xZTA1LTRhNGItOWZkNS01NzFlYmUzZGU5NWMiLCJhY2NvdW50VHlwZSI6IkNIRUNLSU5HIiwiYWNjb3VudE51bWJlciI6Ijg0NTUzNTE2MSIsImFjY291bnROdW1iZXJEaXNwbGF5IjoiKioqKjUxNjEiLCJwcm9kdWN0TmFtZSI6bnVsbCwibmlja25hbWUiOm51bGwsInN0YXR1cyI6Ik9QRU4iLCJhY2NvdW50T3BlbkRhdGUiOiIyMDIyLTA3LTExVDE1OjQwOjQwWiIsImFjY291bnRDbG9zZWREYXRlIjpudWxsLCJjdXJyZW5jeSI6eyJjdXJyZW5jeVJhdGUiOm51bGwsImN1cnJlbmN5Q29kZSI6bnVsbCwib3JpZ2luYWxDdXJyZW5jeUNvZGUiOm51bGx9LCJmaUF0dHJpYnV0ZXMiOlt7Im5hbWUiOiJtZW1iZXJfZ3VpZCIsInZhbHVlIjoiTUJSLWNjNTE0NWJmLTYzZDktNDk4Zi04NzcyLWU0ZWYzMjQxY2NiNiJ9LHsibmFtZSI6Imluc3RpdHV0aW9uX2d1aWQiLCJ2YWx1ZSI6IklOUy1mMWEzMjg1ZC1lODU1LWI2OGYtNmFhNy04YWU3NzVjMGUwZTkifSx7Im5hbWUiOiJleHRlcm5hbF9ndWlkIiwidmFsdWUiOiJhY2NvdW50LWM2ZTc2MjQ0LTg4NjAtNDY0OS05ZDg1LTY1MGQzYWY5ZmViZSJ9XSwicm91dGluZ1RyYW5zaXROdW1iZXIiOm51bGwsImJhbGFuY2VUeXBlIjoiQVNTRVQiLCJpbnRlcmVzdFJhdGUiOm51bGwsImxhc3RBY3Rpdml0eURhdGUiOiIyMDIyLTA3LTExVDE1OjQwOjQwWiIsImJhbGFuY2VBc09mIjoiMjAyMi0wNy0xMVQxNTo0MDo0MFoiLCJjdXJyZW50QmFsYW5jZSI6MTAwMC4wLCJvcGVuaW5nRGF5QmFsYW5jZSI6bnVsbCwiYXZhaWxhYmxlQmFsYW5jZSI6MTAwMC4wLCJhbm51YWxQZXJjZW50YWdlWWllbGQiOm51bGwsIm1hdHVyaXR5RGF0ZSI6bnVsbH19LHsiZGVwb3NpdEFjY291bnQiOnsiYWNjb3VudElkIjoiQUNULWI4MjZlNGMyLTZkNjktNDVkNy1hMTM5LWJlNTY0NDFkNmE1OCIsImFjY291bnRUeXBlIjoiU0FWSU5HUyIsImFjY291bnROdW1iZXIiOiI1OTE4NzE2NjgiLCJhY2NvdW50TnVtYmVyRGlzcGxheSI6IioqKioxNjY4IiwicHJvZHVjdE5hbWUiOm51bGwsIm5pY2tuYW1lIjpudWxsLCJzdGF0dXMiOiJPUEVOIiwiYWNjb3VudE9wZW5EYXRlIjoiMjAyMi0wNy0xMVQxNTo0MDo0MFoiLCJhY2NvdW50Q2xvc2VkRGF0ZSI6bnVsbCwiY3VycmVuY3kiOnsiY3VycmVuY3lSYXRlIjpudWxsLCJjdXJyZW5jeUNvZGUiOm51bGwsIm9yaWdpbmFsQ3VycmVuY3lDb2RlIjpudWxsfSwiZmlBdHRyaWJ1dGVzIjpbeyJuYW1lIjoibWVtYmVyX2d1aWQiLCJ2YWx1ZSI6Ik1CUi1jYzUxNDViZi02M2Q5LTQ5OGYtODc3Mi1lNGVmMzI0MWNjYjYifSx7Im5hbWUiOiJpbnN0aXR1dGlvbl9ndWlkIiwidmFsdWUiOiJJTlMtZjFhMzI4NWQtZTg1NS1iNjhmLTZhYTctOGFlNzc1YzBlMGU5In0seyJuYW1lIjoiZXh0ZXJuYWxfZ3VpZCIsInZhbHVlIjoiYWNjb3VudC1kOTIyNTA4OC1hOTM2LTRkNjctOGQyYy0wY2EyYzgwOGYxMTYifV0sInJvdXRpbmdUcmFuc2l0TnVtYmVyIjpudWxsLCJiYWxhbmNlVHlwZSI6IkFTU0VUIiwiaW50ZXJlc3RSYXRlIjpudWxsLCJsYXN0QWN0aXZpdHlEYXRlIjoiMjAyMi0wNy0xMVQxNTo0MDo0MFoiLCJiYWxhbmNlQXNPZiI6IjIwMjItMDctMTFUMTU6NDA6NDBaIiwiY3VycmVudEJhbGFuY2UiOjEwMDAuMCwib3BlbmluZ0RheUJhbGFuY2UiOm51bGwsImF2YWlsYWJsZUJhbGFuY2UiOjEwMDAuMCwiYW5udWFsUGVyY2VudGFnZVlpZWxkIjpudWxsLCJtYXR1cml0eURhdGUiOm51bGx9fV0sImlkIjoiVVNSLTNlYTdjYzMxLWVkZDYtNDQxNy05YjM1LWRlZTZlMjQ4NDI1YiJ9fSwiaXNzIjoiZGlkOmRodDpzYTcxM2R3N2p5ZzQ0ZWp3Y2RmOGlxY3NlaDdqY3o1MXdqNmZqeGJvb2o0MWlwZWc3NmVvIiwiaWF0IjoxNzA5MzE4NTM5LCJqdGkiOiJodHRwczovL2FwaS5zYW5kLmludGVybmFsLm14L3ZjL3VzZXJzL1VTUi0zZWE3Y2MzMS1lZGQ2LTQ0MTctOWIzNS1kZWU2ZTI0ODQyNWIvbWVtYmVycy9NQlItY2M1MTQ1YmYtNjNkOS00OThmLTg3NzItZTRlZjMyNDFjY2I2L2FjY291bnRzIiwic3ViIjoiVVNSLTNlYTdjYzMxLWVkZDYtNDQxNy05YjM1LWRlZTZlMjQ4NDI1YiJ9._CiFkwbuhKxwwIehEQ1opsi-9NSoIwDqD2HFMw1ROKNuJPdepTXFEd_RDFbbg7lFj05vBXPUL7y9eVVgZXTvDw"
18424 /// ],
18425 /// "type": "string"
18426 /// }
18427 /// }
18428 ///}
18429 /// ```
18430 /// </details>
18431 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
18432 pub struct VcResponse {
18433 #[serde(
18434 rename = "verifiableCredential",
18435 default,
18436 skip_serializing_if = "::std::option::Option::is_none"
18437 )]
18438 pub verifiable_credential: ::std::option::Option<::std::string::String>,
18439 }
18440
18441 impl ::std::convert::From<&VcResponse> for VcResponse {
18442 fn from(value: &VcResponse) -> Self {
18443 value.clone()
18444 }
18445 }
18446
18447 impl ::std::default::Default for VcResponse {
18448 fn default() -> Self {
18449 Self {
18450 verifiable_credential: Default::default(),
18451 }
18452 }
18453 }
18454
18455 ///`WidgetRequest`
18456 ///
18457 /// <details><summary>JSON schema</summary>
18458 ///
18459 /// ```json
18460 ///{
18461 /// "type": "object",
18462 /// "required": [
18463 /// "widget_type"
18464 /// ],
18465 /// "properties": {
18466 /// "client_redirect_url": {
18467 /// "description": "Only use this option if the `widget_type` is set to
18468 /// `connect_widget`. This determines the redirect destination at the end of
18469 /// OAuth when used with `is_mobile_webview: true` or
18470 /// `oauth_referral_source: 'APP'`.\n",
18471 /// "examples": [
18472 /// "https://{yoursite.com}"
18473 /// ],
18474 /// "type": "string"
18475 /// },
18476 /// "color_scheme": {
18477 /// "description": "This option can be passed to any `widget_type` but will not affect [legacy PFM widgets](products/experience/pfm/legacy-widget-overviews/). Load the widget with the specified `color_scheme`; options are `light`, `browser` (respects user's browser setting), and `dark`. Defaults to `light`.",
18478 /// "examples": [
18479 /// "light"
18480 /// ],
18481 /// "type": "string"
18482 /// },
18483 /// "connections_use_case_filter": {
18484 /// "description": "To use this parameter, you must also set
18485 /// `use_cases` in the same request. If `connections_use_case_filter` is set
18486 /// to `true`, the Connections Widget will only show connections (members)
18487 /// with the `use_cases` you set in the same request. For some examples, see
18488 /// [Filter Connections](/products/experience/pfm/widget-overviews/
18489 /// connections-widget#example-1).",
18490 /// "examples": [
18491 /// false
18492 /// ],
18493 /// "type": "boolean"
18494 /// },
18495 /// "current_institution_code": {
18496 /// "description": "Only use this option if the `widget_type` is set to
18497 /// `connect_widget`. Load the widget into the credential view for the
18498 /// specified institution.\n",
18499 /// "examples": [
18500 /// "mxbank"
18501 /// ],
18502 /// "type": "string"
18503 /// },
18504 /// "current_institution_guid": {
18505 /// "description": "Only use this option if the `widget_type` is set to
18506 /// `connect_widget`. Load the widget into the credential view for the
18507 /// specified institution.\n",
18508 /// "examples": [
18509 /// "INS-f1a3285d-e855-b61f-6aa7-8ae575c0e0e9"
18510 /// ],
18511 /// "type": "string"
18512 /// },
18513 /// "current_member_guid": {
18514 /// "description": "Only use this option if the `widget_type` is set to
18515 /// `connect_widget`. Load the widget into a specific member that contains
18516 /// an error or requires multifactor authentication. The widget will
18517 /// determine the best view to load based on the member's current state.
18518 /// `current_member_guid` takes precedence over `current_institution_code`
18519 /// and `current_institution_guid`.\n",
18520 /// "examples": [
18521 /// "MBR-7c6f361b-e582-15b6-60c0-358f12466b4b"
18522 /// ],
18523 /// "type": "string"
18524 /// },
18525 /// "disable_background_agg": {
18526 /// "description": "Only use this option if the `widget_type` is set to
18527 /// `connect_widget`. This determines whether background aggregation is
18528 /// enabled or disabled for the member created by the Connect Widget.
18529 /// Defaults to `false` in `aggregation` mode and `true` in `verification`
18530 /// mode. A global default for all members can be set by reaching out to
18531 /// MX.\n",
18532 /// "examples": [
18533 /// false
18534 /// ],
18535 /// "type": "boolean"
18536 /// },
18537 /// "disable_institution_search": {
18538 /// "description": "Only use this option if the `widget_type` is set to
18539 /// `connect_widget`. This determines whether the institution search is
18540 /// displayed within the Connect Widget. This option must be used with
18541 /// `current_institution_code`, `current_instituion_guid`, or
18542 /// `current_member_guid`. When set to `true`, the institution search
18543 /// feature will be disabled and end users will not be able to navigate to
18544 /// it. Defaults to `false`.\n",
18545 /// "examples": [
18546 /// false
18547 /// ],
18548 /// "type": "boolean"
18549 /// },
18550 /// "enable_app2app": {
18551 /// "description": "Only use this option if the `widget_type` is set to
18552 /// `connect_widget`. This indicates whether OAuth app2app behavior is
18553 /// enabled for institutions that support it. Defaults to `true`. When set
18554 /// to `false`, the widget will **not** direct the end user to the
18555 /// institution's mobile application. This setting is not persistent. This
18556 /// setting currently only affects Chase institutions.\n",
18557 /// "examples": [
18558 /// false
18559 /// ],
18560 /// "type": "boolean"
18561 /// },
18562 /// "include_identity": {
18563 /// "description": "Only use this option if the `widget_type` is set to
18564 /// `connect_widget`. This determines whether an account owner
18565 /// identification (AOI, previously called identity verification) is run in
18566 /// addition to the process specified by the `mode`. Defaults to `false`.
18567 /// This can be set in either `aggregation` or `verification` mode. The AOI
18568 /// runs after the primary process is complete.\n",
18569 /// "examples": [
18570 /// false
18571 /// ],
18572 /// "type": "boolean"
18573 /// },
18574 /// "include_transactions": {
18575 /// "description": "Only use this option if the `widget_type` is set to
18576 /// `connect_widget`. This determines whether transaction data are
18577 /// retrieved. Defaults to `true` in aggregation mode and `false` in
18578 /// verification mode. This can be set in either `aggregation` or
18579 /// `verification` mode. This option does not affect future foreground or
18580 /// background aggregations.\n",
18581 /// "examples": [
18582 /// true
18583 /// ],
18584 /// "type": "boolean"
18585 /// },
18586 /// "insight_guid": {
18587 /// "description": "Only use this option if the `widget_type` is set to
18588 /// `pulse_widget`. Set this to the insight guid you want to appear at the
18589 /// top of the insights feed.\n",
18590 /// "type": [
18591 /// "string",
18592 /// "null"
18593 /// ]
18594 /// },
18595 /// "is_mobile_webview": {
18596 /// "description": "This option is for all `widget_type`s. This
18597 /// configures the widget to render in a mobile WebView. JavaScript event
18598 /// postMessages are replaced with URL updates.\n",
18599 /// "examples": [
18600 /// false
18601 /// ],
18602 /// "type": "boolean"
18603 /// },
18604 /// "iso_country_code": {
18605 /// "description": "An array of strings that filters institutions in
18606 /// the widget by the specified country code. Acceptable codes include `US`,
18607 /// `CA`, and `MX` (Mexico).\n",
18608 /// "examples": [
18609 /// [
18610 /// "US",
18611 /// "CA"
18612 /// ]
18613 /// ],
18614 /// "type": "array",
18615 /// "items": {
18616 /// "type": "string"
18617 /// }
18618 /// },
18619 /// "microwidget_instance_id": {
18620 /// "description": "Only use this option if the `widget_type` is set to
18621 /// `micro_pulse_carousel_widget`. Set this to a unique value for each
18622 /// instance of the Micro Widget. This lets us collect unique data for each
18623 /// instance of the widget.\n",
18624 /// "type": [
18625 /// "string",
18626 /// "null"
18627 /// ]
18628 /// },
18629 /// "mode": {
18630 /// "description": "Only use this option if the `widget_type` is set to
18631 /// `connect_widget`. `mode` is the most important option for the Connect
18632 /// Widget. This determines what kind of process Connect will run, which
18633 /// affects how you should set many other options. Defaults to
18634 /// `aggregation`. `aggregation` mode retrieves account and transaction
18635 /// data; in other words, this runs a standard aggregation. `verification`
18636 /// mode retrieves account numbers and routing/transit numbers; in other
18637 /// words, it runs an Instant Account Verification (IAV). By default,
18638 /// verification mode does not retrieve transaction data; this default can
18639 /// be modified with secondary options. By default, background aggregation
18640 /// is disabled for all members created in verification mode; this default
18641 /// can be modified with secondary options.\n",
18642 /// "examples": [
18643 /// "aggregation"
18644 /// ],
18645 /// "type": "string"
18646 /// },
18647 /// "oauth_referral_source": {
18648 /// "description": "Only use this option if the `widget_type` is set to
18649 /// `connect_widget`. This determines how MX will respond to the result of
18650 /// an OAuth flow. When set to `APP`, MX will redirect to the URI specified
18651 /// in the `ui_message_webview_url_scheme`. When set to `BROWSER`, MX will
18652 /// send a postMessage but not redirect. If `is_mobile_webview` is `true`,
18653 /// this defaults to `APP`. If false, it defaults to `BROWSER`.\n",
18654 /// "examples": [
18655 /// "BROWSER"
18656 /// ],
18657 /// "type": "string"
18658 /// },
18659 /// "ui_message_version": {
18660 /// "description": "This option is for all `widget_type`s. This
18661 /// determines which version of postMessage events are triggered. Defaults
18662 /// to 4. All new implementations must use version 4. Prior versions are
18663 /// deprecated.\n",
18664 /// "examples": [
18665 /// 4
18666 /// ],
18667 /// "type": "integer"
18668 /// },
18669 /// "ui_message_webview_url_scheme": {
18670 /// "description": "Only use this option if the `widget_type` is set to
18671 /// `connect_widget`. This is a client-defined scheme used in OAuth
18672 /// redirects in WebViews; also used in URL updates when these replace
18673 /// postMessages in WebViews. Defaults to `mx`.\n",
18674 /// "type": "string"
18675 /// },
18676 /// "update_credentials": {
18677 /// "description": "Only use this option if the `widget_type` is set to
18678 /// `connect_widget`. Load the widget into a view that allows them to update
18679 /// the current member. Optionally used with `current_member_guid`. This
18680 /// option should be used sparingly. The best practice is to use
18681 /// `current_member_guid` and let the widget resolve the issue.\n",
18682 /// "examples": [
18683 /// false
18684 /// ],
18685 /// "type": "boolean"
18686 /// },
18687 /// "use_cases": {
18688 /// "description": "The use case that will be associated with any
18689 /// members created through the widget. Valid values are `PFM` and/or
18690 /// `MONEY_MOVEMENT`. This is **required** if you've met with MX, opted in
18691 /// to using this field, and are requesting a widget with a `widget_type` of
18692 /// `connect_widget` or `connections_widget`.",
18693 /// "examples": [
18694 /// [
18695 /// "PFM"
18696 /// ]
18697 /// ],
18698 /// "type": "array",
18699 /// "items": {
18700 /// "type": "string",
18701 /// "enum": [
18702 /// "MONEY_MOVEMENT",
18703 /// "PFM"
18704 /// ]
18705 /// }
18706 /// },
18707 /// "widget_type": {
18708 /// "description": "This determines which widget URL you'll
18709 /// receive.\n\nSee [Widget
18710 /// Types](/api-reference/platform-api/reference/widget-types) for a list of
18711 /// potential values. Additional request parameters may only apply to some
18712 /// widget types.\n",
18713 /// "examples": [
18714 /// "connect_widget"
18715 /// ],
18716 /// "type": "string"
18717 /// }
18718 /// }
18719 ///}
18720 /// ```
18721 /// </details>
18722 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
18723 pub struct WidgetRequest {
18724 ///Only use this option if the `widget_type` is set to
18725 /// `connect_widget`. This determines the redirect destination at the
18726 /// end of OAuth when used with `is_mobile_webview: true` or
18727 /// `oauth_referral_source: 'APP'`.
18728 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
18729 pub client_redirect_url: ::std::option::Option<::std::string::String>,
18730 ///This option can be passed to any `widget_type` but will not affect
18731 /// [legacy PFM
18732 /// widgets](products/experience/pfm/legacy-widget-overviews/). Load the
18733 /// widget with the specified `color_scheme`; options are `light`,
18734 /// `browser` (respects user's browser setting), and `dark`. Defaults to
18735 /// `light`.
18736 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
18737 pub color_scheme: ::std::option::Option<::std::string::String>,
18738 ///To use this parameter, you must also set `use_cases` in the same
18739 /// request. If `connections_use_case_filter` is set to `true`, the
18740 /// Connections Widget will only show connections (members) with the
18741 /// `use_cases` you set in the same request. For some examples, see
18742 /// [Filter Connections](/products/experience/pfm/widget-overviews/
18743 /// connections-widget#example-1).
18744 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
18745 pub connections_use_case_filter: ::std::option::Option<bool>,
18746 ///Only use this option if the `widget_type` is set to
18747 /// `connect_widget`. Load the widget into the credential view for the
18748 /// specified institution.
18749 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
18750 pub current_institution_code: ::std::option::Option<::std::string::String>,
18751 ///Only use this option if the `widget_type` is set to
18752 /// `connect_widget`. Load the widget into the credential view for the
18753 /// specified institution.
18754 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
18755 pub current_institution_guid: ::std::option::Option<::std::string::String>,
18756 ///Only use this option if the `widget_type` is set to
18757 /// `connect_widget`. Load the widget into a specific member that
18758 /// contains an error or requires multifactor authentication. The widget
18759 /// will determine the best view to load based on the member's current
18760 /// state. `current_member_guid` takes precedence over
18761 /// `current_institution_code` and `current_institution_guid`.
18762 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
18763 pub current_member_guid: ::std::option::Option<::std::string::String>,
18764 ///Only use this option if the `widget_type` is set to
18765 /// `connect_widget`. This determines whether background aggregation is
18766 /// enabled or disabled for the member created by the Connect Widget.
18767 /// Defaults to `false` in `aggregation` mode and `true` in
18768 /// `verification` mode. A global default for all members can be set by
18769 /// reaching out to MX.
18770 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
18771 pub disable_background_agg: ::std::option::Option<bool>,
18772 ///Only use this option if the `widget_type` is set to
18773 /// `connect_widget`. This determines whether the institution search is
18774 /// displayed within the Connect Widget. This option must be used with
18775 /// `current_institution_code`, `current_instituion_guid`, or
18776 /// `current_member_guid`. When set to `true`, the institution search
18777 /// feature will be disabled and end users will not be able to navigate
18778 /// to it. Defaults to `false`.
18779 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
18780 pub disable_institution_search: ::std::option::Option<bool>,
18781 ///Only use this option if the `widget_type` is set to
18782 /// `connect_widget`. This indicates whether OAuth app2app behavior is
18783 /// enabled for institutions that support it. Defaults to `true`. When
18784 /// set to `false`, the widget will **not** direct the end user to the
18785 /// institution's mobile application. This setting is not persistent.
18786 /// This setting currently only affects Chase institutions.
18787 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
18788 pub enable_app2app: ::std::option::Option<bool>,
18789 ///Only use this option if the `widget_type` is set to
18790 /// `connect_widget`. This determines whether an account owner
18791 /// identification (AOI, previously called identity verification) is run
18792 /// in addition to the process specified by the `mode`. Defaults to
18793 /// `false`. This can be set in either `aggregation` or `verification`
18794 /// mode. The AOI runs after the primary process is complete.
18795 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
18796 pub include_identity: ::std::option::Option<bool>,
18797 ///Only use this option if the `widget_type` is set to
18798 /// `connect_widget`. This determines whether transaction data are
18799 /// retrieved. Defaults to `true` in aggregation mode and `false` in
18800 /// verification mode. This can be set in either `aggregation` or
18801 /// `verification` mode. This option does not affect future foreground
18802 /// or background aggregations.
18803 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
18804 pub include_transactions: ::std::option::Option<bool>,
18805 ///Only use this option if the `widget_type` is set to `pulse_widget`.
18806 /// Set this to the insight guid you want to appear at the top of the
18807 /// insights feed.
18808 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
18809 pub insight_guid: ::std::option::Option<::std::string::String>,
18810 ///This option is for all `widget_type`s. This configures the widget to
18811 /// render in a mobile WebView. JavaScript event postMessages are
18812 /// replaced with URL updates.
18813 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
18814 pub is_mobile_webview: ::std::option::Option<bool>,
18815 ///An array of strings that filters institutions in the widget by the
18816 /// specified country code. Acceptable codes include `US`, `CA`, and
18817 /// `MX` (Mexico).
18818 #[serde(default, skip_serializing_if = "::std::vec::Vec::is_empty")]
18819 pub iso_country_code: ::std::vec::Vec<::std::string::String>,
18820 ///Only use this option if the `widget_type` is set to
18821 /// `micro_pulse_carousel_widget`. Set this to a unique value for each
18822 /// instance of the Micro Widget. This lets us collect unique data for
18823 /// each instance of the widget.
18824 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
18825 pub microwidget_instance_id: ::std::option::Option<::std::string::String>,
18826 ///Only use this option if the `widget_type` is set to
18827 /// `connect_widget`. `mode` is the most important option for the
18828 /// Connect Widget. This determines what kind of process Connect will
18829 /// run, which affects how you should set many other options. Defaults
18830 /// to `aggregation`. `aggregation` mode retrieves account and
18831 /// transaction data; in other words, this runs a standard aggregation.
18832 /// `verification` mode retrieves account numbers and routing/transit
18833 /// numbers; in other words, it runs an Instant Account Verification
18834 /// (IAV). By default, verification mode does not retrieve transaction
18835 /// data; this default can be modified with secondary options. By
18836 /// default, background aggregation is disabled for all members created
18837 /// in verification mode; this default can be modified with secondary
18838 /// options.
18839 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
18840 pub mode: ::std::option::Option<::std::string::String>,
18841 ///Only use this option if the `widget_type` is set to
18842 /// `connect_widget`. This determines how MX will respond to the result
18843 /// of an OAuth flow. When set to `APP`, MX will redirect to the URI
18844 /// specified in the `ui_message_webview_url_scheme`. When set to
18845 /// `BROWSER`, MX will send a postMessage but not redirect. If
18846 /// `is_mobile_webview` is `true`, this defaults to `APP`. If false, it
18847 /// defaults to `BROWSER`.
18848 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
18849 pub oauth_referral_source: ::std::option::Option<::std::string::String>,
18850 ///This option is for all `widget_type`s. This determines which version
18851 /// of postMessage events are triggered. Defaults to 4. All new
18852 /// implementations must use version 4. Prior versions are deprecated.
18853 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
18854 pub ui_message_version: ::std::option::Option<i64>,
18855 ///Only use this option if the `widget_type` is set to
18856 /// `connect_widget`. This is a client-defined scheme used in OAuth
18857 /// redirects in WebViews; also used in URL updates when these replace
18858 /// postMessages in WebViews. Defaults to `mx`.
18859 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
18860 pub ui_message_webview_url_scheme: ::std::option::Option<::std::string::String>,
18861 ///Only use this option if the `widget_type` is set to
18862 /// `connect_widget`. Load the widget into a view that allows them to
18863 /// update the current member. Optionally used with
18864 /// `current_member_guid`. This option should be used sparingly. The
18865 /// best practice is to use `current_member_guid` and let the widget
18866 /// resolve the issue.
18867 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
18868 pub update_credentials: ::std::option::Option<bool>,
18869 ///The use case that will be associated with any members created
18870 /// through the widget. Valid values are `PFM` and/or `MONEY_MOVEMENT`.
18871 /// This is **required** if you've met with MX, opted in to using this
18872 /// field, and are requesting a widget with a `widget_type` of
18873 /// `connect_widget` or `connections_widget`.
18874 #[serde(default, skip_serializing_if = "::std::vec::Vec::is_empty")]
18875 pub use_cases: ::std::vec::Vec<WidgetRequestUseCasesItem>,
18876 ///This determines which widget URL you'll receive.
18877 ///
18878 ///See [Widget
18879 /// Types](/api-reference/platform-api/reference/widget-types) for a
18880 /// list of potential values. Additional request parameters may only
18881 /// apply to some widget types.
18882 pub widget_type: ::std::string::String,
18883 }
18884
18885 impl ::std::convert::From<&WidgetRequest> for WidgetRequest {
18886 fn from(value: &WidgetRequest) -> Self {
18887 value.clone()
18888 }
18889 }
18890
18891 ///`WidgetRequestBody`
18892 ///
18893 /// <details><summary>JSON schema</summary>
18894 ///
18895 /// ```json
18896 ///{
18897 /// "type": "object",
18898 /// "properties": {
18899 /// "widget_url": {
18900 /// "$ref": "#/components/schemas/WidgetRequest"
18901 /// }
18902 /// }
18903 ///}
18904 /// ```
18905 /// </details>
18906 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
18907 pub struct WidgetRequestBody {
18908 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
18909 pub widget_url: ::std::option::Option<WidgetRequest>,
18910 }
18911
18912 impl ::std::convert::From<&WidgetRequestBody> for WidgetRequestBody {
18913 fn from(value: &WidgetRequestBody) -> Self {
18914 value.clone()
18915 }
18916 }
18917
18918 impl ::std::default::Default for WidgetRequestBody {
18919 fn default() -> Self {
18920 Self {
18921 widget_url: Default::default(),
18922 }
18923 }
18924 }
18925
18926 ///`WidgetRequestUseCasesItem`
18927 ///
18928 /// <details><summary>JSON schema</summary>
18929 ///
18930 /// ```json
18931 ///{
18932 /// "type": "string",
18933 /// "enum": [
18934 /// "MONEY_MOVEMENT",
18935 /// "PFM"
18936 /// ]
18937 ///}
18938 /// ```
18939 /// </details>
18940 #[derive(
18941 :: serde :: Deserialize,
18942 :: serde :: Serialize,
18943 Clone,
18944 Copy,
18945 Debug,
18946 Eq,
18947 Hash,
18948 Ord,
18949 PartialEq,
18950 PartialOrd,
18951 )]
18952 pub enum WidgetRequestUseCasesItem {
18953 #[serde(rename = "MONEY_MOVEMENT")]
18954 MoneyMovement,
18955 #[serde(rename = "PFM")]
18956 Pfm,
18957 }
18958
18959 impl ::std::convert::From<&Self> for WidgetRequestUseCasesItem {
18960 fn from(value: &WidgetRequestUseCasesItem) -> Self {
18961 value.clone()
18962 }
18963 }
18964
18965 impl ::std::fmt::Display for WidgetRequestUseCasesItem {
18966 fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
18967 match *self {
18968 Self::MoneyMovement => f.write_str("MONEY_MOVEMENT"),
18969 Self::Pfm => f.write_str("PFM"),
18970 }
18971 }
18972 }
18973
18974 impl ::std::str::FromStr for WidgetRequestUseCasesItem {
18975 type Err = self::error::ConversionError;
18976 fn from_str(value: &str) -> ::std::result::Result<Self, self::error::ConversionError> {
18977 match value {
18978 "MONEY_MOVEMENT" => Ok(Self::MoneyMovement),
18979 "PFM" => Ok(Self::Pfm),
18980 _ => Err("invalid value".into()),
18981 }
18982 }
18983 }
18984
18985 impl ::std::convert::TryFrom<&str> for WidgetRequestUseCasesItem {
18986 type Error = self::error::ConversionError;
18987 fn try_from(value: &str) -> ::std::result::Result<Self, self::error::ConversionError> {
18988 value.parse()
18989 }
18990 }
18991
18992 impl ::std::convert::TryFrom<&::std::string::String> for WidgetRequestUseCasesItem {
18993 type Error = self::error::ConversionError;
18994 fn try_from(
18995 value: &::std::string::String,
18996 ) -> ::std::result::Result<Self, self::error::ConversionError> {
18997 value.parse()
18998 }
18999 }
19000
19001 impl ::std::convert::TryFrom<::std::string::String> for WidgetRequestUseCasesItem {
19002 type Error = self::error::ConversionError;
19003 fn try_from(
19004 value: ::std::string::String,
19005 ) -> ::std::result::Result<Self, self::error::ConversionError> {
19006 value.parse()
19007 }
19008 }
19009
19010 ///`WidgetResponse`
19011 ///
19012 /// <details><summary>JSON schema</summary>
19013 ///
19014 /// ```json
19015 ///{
19016 /// "type": "object",
19017 /// "properties": {
19018 /// "type": {
19019 /// "examples": [
19020 /// "connect_widget"
19021 /// ],
19022 /// "type": [
19023 /// "string",
19024 /// "null"
19025 /// ]
19026 /// },
19027 /// "url": {
19028 /// "examples": [
19029 /// "https://int-widgets.moneydesktop.com/md/connect/yxcdk7f1nb99jwApp34lA24m0AZ8rzprgmw17gm8z8h2AzjyAnd1rj42qfv42r3xnn07Amfwlg3j09hwp8bkq8tc5z21j33xjggmp2qtlpkz2v4gywfhfn31l44tx2w91bfc2thc58j4syqp0hgxcyvA4g7754hk7gjc56kt7tc36s45mmkdz2jqqqydspytmtr3dAb9jh6fkb24f3zkfpdjj0v77f0vmrtzvzxkmxz7dklsq8gd0gstkbhlw5bgpgc3m9mAtpAcr2w15gwy5xc4blgxppl42Avnm63291z3cyp0wm3lqgmvgzdAddct423gAdqxdlfx5d4mvc0ck2gt7ktqgks4vxq1pAy5"
19030 /// ],
19031 /// "type": [
19032 /// "string",
19033 /// "null"
19034 /// ]
19035 /// },
19036 /// "user_id": {
19037 /// "examples": [
19038 /// "U-jeff-201709221210"
19039 /// ],
19040 /// "type": [
19041 /// "string",
19042 /// "null"
19043 /// ]
19044 /// }
19045 /// }
19046 ///}
19047 /// ```
19048 /// </details>
19049 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
19050 pub struct WidgetResponse {
19051 #[serde(
19052 rename = "type",
19053 default,
19054 skip_serializing_if = "::std::option::Option::is_none"
19055 )]
19056 pub type_: ::std::option::Option<::std::string::String>,
19057 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
19058 pub url: ::std::option::Option<::std::string::String>,
19059 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
19060 pub user_id: ::std::option::Option<::std::string::String>,
19061 }
19062
19063 impl ::std::convert::From<&WidgetResponse> for WidgetResponse {
19064 fn from(value: &WidgetResponse) -> Self {
19065 value.clone()
19066 }
19067 }
19068
19069 impl ::std::default::Default for WidgetResponse {
19070 fn default() -> Self {
19071 Self {
19072 type_: Default::default(),
19073 url: Default::default(),
19074 user_id: Default::default(),
19075 }
19076 }
19077 }
19078
19079 ///`WidgetResponseBody`
19080 ///
19081 /// <details><summary>JSON schema</summary>
19082 ///
19083 /// ```json
19084 ///{
19085 /// "type": "object",
19086 /// "properties": {
19087 /// "widget_url": {
19088 /// "$ref": "#/components/schemas/WidgetResponse"
19089 /// }
19090 /// }
19091 ///}
19092 /// ```
19093 /// </details>
19094 #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
19095 pub struct WidgetResponseBody {
19096 #[serde(default, skip_serializing_if = "::std::option::Option::is_none")]
19097 pub widget_url: ::std::option::Option<WidgetResponse>,
19098 }
19099
19100 impl ::std::convert::From<&WidgetResponseBody> for WidgetResponseBody {
19101 fn from(value: &WidgetResponseBody) -> Self {
19102 value.clone()
19103 }
19104 }
19105
19106 impl ::std::default::Default for WidgetResponseBody {
19107 fn default() -> Self {
19108 Self {
19109 widget_url: Default::default(),
19110 }
19111 }
19112 }
19113}
19114
19115#[derive(Clone, Debug)]
19116///Client for MX Platform API
19117///
19118///The MX Platform API is a powerful, fully-featured API designed to make
19119/// aggregating and enhancing financial data easy and reliable. It can
19120/// seamlessly connect your app or website to tens of thousands of financial
19121/// institutions.
19122///
19123///Just getting started? See our [use case guides](/use-cases/).
19124///
19125///
19126///Version: 20111101
19127pub struct Client {
19128 pub(crate) baseurl: String,
19129 pub(crate) client: reqwest::Client,
19130}
19131
19132impl Client {
19133 /// Create a new client.
19134 ///
19135 /// `baseurl` is the base URL provided to the internal
19136 /// `reqwest::Client`, and should include a scheme and hostname,
19137 /// as well as port and a path stem if applicable.
19138 pub fn new(baseurl: &str) -> Self {
19139 #[cfg(not(target_arch = "wasm32"))]
19140 let client = {
19141 let dur = ::std::time::Duration::from_secs(15u64);
19142 reqwest::ClientBuilder::new()
19143 .connect_timeout(dur)
19144 .timeout(dur)
19145 };
19146 #[cfg(target_arch = "wasm32")]
19147 let client = reqwest::ClientBuilder::new();
19148 Self::new_with_client(baseurl, client.build().unwrap())
19149 }
19150
19151 /// Construct a new client with an existing `reqwest::Client`,
19152 /// allowing more control over its configuration.
19153 ///
19154 /// `baseurl` is the base URL provided to the internal
19155 /// `reqwest::Client`, and should include a scheme and hostname,
19156 /// as well as port and a path stem if applicable.
19157 pub fn new_with_client(baseurl: &str, client: reqwest::Client) -> Self {
19158 Self {
19159 baseurl: baseurl.to_string(),
19160 client,
19161 }
19162 }
19163}
19164
19165impl ClientInfo<()> for Client {
19166 fn api_version() -> &'static str {
19167 "20111101"
19168 }
19169
19170 fn baseurl(&self) -> &str {
19171 self.baseurl.as_str()
19172 }
19173
19174 fn client(&self) -> &reqwest::Client {
19175 &self.client
19176 }
19177
19178 fn inner(&self) -> &() {
19179 &()
19180 }
19181}
19182
19183impl ClientHooks<()> for &Client {}
19184#[allow(clippy::all)]
19185impl Client {
19186 ///Request an authorization code
19187 ///
19188 ///Clients use this endpoint to request an authorization code according to
19189 /// the parameters specified in the scope. Clients then pass this code to
19190 /// processors. Processor access is scoped only to the GUIDs and features
19191 /// specified in this request. Before requesting an authorization code which
19192 /// includes a member in the scope, clients must have verified that member.
19193 ///
19194 ///Sends a `POST` request to `/authorization_code`
19195 ///
19196 ///Arguments:
19197 /// - `body`: The scope for the authorization code.
19198 pub async fn request_authorization_code<'a>(
19199 &'a self,
19200 body: &'a types::AuthorizationCodeRequestBody,
19201 ) -> Result<ResponseValue<types::AuthorizationCodeResponseBody>, Error<()>> {
19202 let url = format!("{}/authorization_code", self.baseurl,);
19203 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
19204 header_map.append(
19205 ::reqwest::header::HeaderName::from_static("api-version"),
19206 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
19207 );
19208 #[allow(unused_mut)]
19209 let mut request = self
19210 .client
19211 .post(url)
19212 .header(
19213 ::reqwest::header::ACCEPT,
19214 ::reqwest::header::HeaderValue::from_static("application/json"),
19215 )
19216 .json(&body)
19217 .headers(header_map)
19218 .build()?;
19219 let info = OperationInfo {
19220 operation_id: "request_authorization_code",
19221 };
19222 self.pre(&mut request, &info).await?;
19223 let result = self.exec(request, &info).await;
19224 self.post(&result, &info).await?;
19225 let response = result?;
19226 match response.status().as_u16() {
19227 200u16 => ResponseValue::from_response(response).await,
19228 _ => Err(Error::UnexpectedResponse(response)),
19229 }
19230 }
19231
19232 ///Read ACH Return
19233 ///
19234 ///:::warning
19235 ///The features documented here are in a beta state, and this documentation
19236 /// is considered draft material subject to frequent change. :::
19237 ///
19238 ///Use this endpoint to get an ACH return by its `guid` or `id`.
19239 ///
19240 ///
19241 ///Sends a `GET` request to `/ach_returns/{ach_return_guid}`
19242 ///
19243 ///Arguments:
19244 /// - `ach_return_guid`: The unique identifier (`guid`) for the ACH return.
19245 /// Defined by MX.
19246 pub async fn read_ach_retrun<'a>(
19247 &'a self,
19248 ach_return_guid: &'a str,
19249 ) -> Result<ResponseValue<types::AchReturnResponseBody>, Error<()>> {
19250 let url = format!(
19251 "{}/ach_returns/{}",
19252 self.baseurl,
19253 encode_path(&ach_return_guid.to_string()),
19254 );
19255 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
19256 header_map.append(
19257 ::reqwest::header::HeaderName::from_static("api-version"),
19258 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
19259 );
19260 #[allow(unused_mut)]
19261 let mut request = self
19262 .client
19263 .get(url)
19264 .header(
19265 ::reqwest::header::ACCEPT,
19266 ::reqwest::header::HeaderValue::from_static("application/json"),
19267 )
19268 .headers(header_map)
19269 .build()?;
19270 let info = OperationInfo {
19271 operation_id: "read_ach_retrun",
19272 };
19273 self.pre(&mut request, &info).await?;
19274 let result = self.exec(request, &info).await;
19275 self.post(&result, &info).await?;
19276 let response = result?;
19277 match response.status().as_u16() {
19278 200u16 => ResponseValue::from_response(response).await,
19279 _ => Err(Error::UnexpectedResponse(response)),
19280 }
19281 }
19282
19283 ///List ACH Returns
19284 ///
19285 ///:::warning
19286 ///The features documented here are in a beta state, and this documentation
19287 /// is considered draft material subject to frequent change. :::
19288 ///
19289 ///Use this endpoint to get all ACH returns.
19290 ///
19291 ///
19292 ///Sends a `GET` request to `/ach_returns`
19293 ///
19294 ///Arguments:
19295 /// - `institution_guid`: The identifier for the institution associated with
19296 /// the ACH return. Defined by MX.
19297 /// - `page`: Results are paginated. Specify current page.
19298 /// - `records_per_page`: This specifies the number of records to be
19299 /// returned on each page. Defaults to `25`. The valid range is from `10`
19300 /// to `100`. If the value exceeds `100`, the default value of `25` will
19301 /// be used instead.
19302 /// - `resolved_status_at`: The date and time when the return was resolved
19303 /// by the Receiving Financial Depository Institution (RDFI) in ISO 8601
19304 /// format without timestamp
19305 /// - `return_code`: The associated ACH return code and notice of change
19306 /// code. See [Return
19307 /// Codes](/api-reference/platform-api/reference/ach-return-fields#
19308 /// return-codes) for a complete list.
19309 /// - `return_status`: The status of the return. See [Return
19310 /// Statuses](/api-reference/platform-api/reference/ach-return-fields#
19311 /// return-status) for a complete list.
19312 /// - `returned_at`: The date and time when the return was reported by the
19313 /// Receiving Financial Depository Institution (RDFI) in ISO 8601 format
19314 /// without timestamp.
19315 pub async fn list_ach_retruns<'a>(
19316 &'a self,
19317 institution_guid: Option<&'a str>,
19318 page: Option<i64>,
19319 records_per_page: Option<i64>,
19320 resolved_status_at: Option<&'a str>,
19321 return_code: Option<&'a str>,
19322 return_status: Option<&'a str>,
19323 returned_at: Option<&'a str>,
19324 ) -> Result<ResponseValue<types::AchReturnsResponseBody>, Error<()>> {
19325 let url = format!("{}/ach_returns", self.baseurl,);
19326 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
19327 header_map.append(
19328 ::reqwest::header::HeaderName::from_static("api-version"),
19329 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
19330 );
19331 #[allow(unused_mut)]
19332 let mut request = self
19333 .client
19334 .get(url)
19335 .header(
19336 ::reqwest::header::ACCEPT,
19337 ::reqwest::header::HeaderValue::from_static("application/json"),
19338 )
19339 .query(&progenitor_client::QueryParam::new(
19340 "institution_guid",
19341 &institution_guid,
19342 ))
19343 .query(&progenitor_client::QueryParam::new("page", &page))
19344 .query(&progenitor_client::QueryParam::new(
19345 "records_per_page",
19346 &records_per_page,
19347 ))
19348 .query(&progenitor_client::QueryParam::new(
19349 "resolved_status_at",
19350 &resolved_status_at,
19351 ))
19352 .query(&progenitor_client::QueryParam::new(
19353 "return_code",
19354 &return_code,
19355 ))
19356 .query(&progenitor_client::QueryParam::new(
19357 "return_status",
19358 &return_status,
19359 ))
19360 .query(&progenitor_client::QueryParam::new(
19361 "returned_at",
19362 &returned_at,
19363 ))
19364 .headers(header_map)
19365 .build()?;
19366 let info = OperationInfo {
19367 operation_id: "list_ach_retruns",
19368 };
19369 self.pre(&mut request, &info).await?;
19370 let result = self.exec(request, &info).await;
19371 self.post(&result, &info).await?;
19372 let response = result?;
19373 match response.status().as_u16() {
19374 200u16 => ResponseValue::from_response(response).await,
19375 _ => Err(Error::UnexpectedResponse(response)),
19376 }
19377 }
19378
19379 ///Create ACH Return
19380 ///
19381 ///:::warning
19382 ///The features documented here are in a beta state, and this documentation
19383 /// is considered draft material subject to frequent change. :::
19384 ///
19385 ///Use this endpoint to create an ACH return in our system.
19386 ///
19387 ///
19388 ///Sends a `POST` request to `/ach_returns`
19389 ///
19390 ///Arguments:
19391 /// - `body`: ACH return object to be created.
19392 pub async fn create_ach_return<'a>(
19393 &'a self,
19394 body: &'a types::AchReturnCreateRequestBody,
19395 ) -> Result<ResponseValue<types::AchReturnResponseBody>, Error<()>> {
19396 let url = format!("{}/ach_returns", self.baseurl,);
19397 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
19398 header_map.append(
19399 ::reqwest::header::HeaderName::from_static("api-version"),
19400 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
19401 );
19402 #[allow(unused_mut)]
19403 let mut request = self
19404 .client
19405 .post(url)
19406 .header(
19407 ::reqwest::header::ACCEPT,
19408 ::reqwest::header::HeaderValue::from_static("application/json"),
19409 )
19410 .json(&body)
19411 .headers(header_map)
19412 .build()?;
19413 let info = OperationInfo {
19414 operation_id: "create_ach_return",
19415 };
19416 self.pre(&mut request, &info).await?;
19417 let result = self.exec(request, &info).await;
19418 self.post(&result, &info).await?;
19419 let response = result?;
19420 match response.status().as_u16() {
19421 200u16 => ResponseValue::from_response(response).await,
19422 _ => Err(Error::UnexpectedResponse(response)),
19423 }
19424 }
19425
19426 ///List default categories
19427 ///
19428 ///Use this endpoint to retrieve a list of all the default categories and
19429 /// subcategories offered within the MX Platform API. In other words, each
19430 /// item in the returned list will have its `is_default` field set to
19431 /// `true`. There are currently 119 default categories and subcategories.
19432 /// Both the _list default categories_ and _list default categories by user_
19433 /// endpoints return the same results. The different routes are provided for
19434 /// convenience.
19435 ///
19436 ///Sends a `GET` request to `/categories/default`
19437 ///
19438 ///Arguments:
19439 /// - `page`: Results are paginated. Specify current page.
19440 /// - `records_per_page`: This specifies the number of records to be
19441 /// returned on each page. Defaults to `25`. The valid range is from `10`
19442 /// to `100`. If the value exceeds `100`, the default value of `25` will
19443 /// be used instead.
19444 pub async fn list_default_categories<'a>(
19445 &'a self,
19446 page: Option<i64>,
19447 records_per_page: Option<i64>,
19448 ) -> Result<ResponseValue<types::CategoriesResponseBody>, Error<()>> {
19449 let url = format!("{}/categories/default", self.baseurl,);
19450 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
19451 header_map.append(
19452 ::reqwest::header::HeaderName::from_static("api-version"),
19453 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
19454 );
19455 #[allow(unused_mut)]
19456 let mut request = self
19457 .client
19458 .get(url)
19459 .header(
19460 ::reqwest::header::ACCEPT,
19461 ::reqwest::header::HeaderValue::from_static("application/json"),
19462 )
19463 .query(&progenitor_client::QueryParam::new("page", &page))
19464 .query(&progenitor_client::QueryParam::new(
19465 "records_per_page",
19466 &records_per_page,
19467 ))
19468 .headers(header_map)
19469 .build()?;
19470 let info = OperationInfo {
19471 operation_id: "list_default_categories",
19472 };
19473 self.pre(&mut request, &info).await?;
19474 let result = self.exec(request, &info).await;
19475 self.post(&result, &info).await?;
19476 let response = result?;
19477 match response.status().as_u16() {
19478 200u16 => ResponseValue::from_response(response).await,
19479 _ => Err(Error::UnexpectedResponse(response)),
19480 }
19481 }
19482
19483 ///Read a default category
19484 ///
19485 ///Use this endpoint to read the attributes of a default category.
19486 ///
19487 ///Sends a `GET` request to `/categories/{category_guid}`
19488 ///
19489 ///Arguments:
19490 /// - `category_guid`: The unique id for a `category`.
19491 pub async fn read_default_category<'a>(
19492 &'a self,
19493 category_guid: &'a str,
19494 ) -> Result<ResponseValue<types::CategoryResponseBody>, Error<()>> {
19495 let url = format!(
19496 "{}/categories/{}",
19497 self.baseurl,
19498 encode_path(&category_guid.to_string()),
19499 );
19500 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
19501 header_map.append(
19502 ::reqwest::header::HeaderName::from_static("api-version"),
19503 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
19504 );
19505 #[allow(unused_mut)]
19506 let mut request = self
19507 .client
19508 .get(url)
19509 .header(
19510 ::reqwest::header::ACCEPT,
19511 ::reqwest::header::HeaderValue::from_static("application/json"),
19512 )
19513 .headers(header_map)
19514 .build()?;
19515 let info = OperationInfo {
19516 operation_id: "read_default_category",
19517 };
19518 self.pre(&mut request, &info).await?;
19519 let result = self.exec(request, &info).await;
19520 self.post(&result, &info).await?;
19521 let response = result?;
19522 match response.status().as_u16() {
19523 200u16 => ResponseValue::from_response(response).await,
19524 _ => Err(Error::UnexpectedResponse(response)),
19525 }
19526 }
19527
19528 ///List institutions
19529 ///
19530 ///This endpoint returns a list of institutions based on the specified
19531 /// search term or parameter.
19532 ///
19533 ///Sends a `GET` request to `/institutions`
19534 ///
19535 ///Arguments:
19536 /// - `iso_country_code`: An array of strings that filters institutions in
19537 /// the widget by the specified country code. Acceptable codes include
19538 /// `US`, `CA`, and `MX` (Mexico).
19539 /// - `name`: This will list only institutions in which the appended string
19540 /// appears.
19541 /// - `page`: Results are paginated. Specify current page.
19542 /// - `records_per_page`: This specifies the number of records to be
19543 /// returned on each page. Defaults to `25`. The valid range is from `10`
19544 /// to `100`. If the value exceeds `100`, the default value of `25` will
19545 /// be used instead.
19546 /// - `supports_account_identification`: Filter only institutions which
19547 /// support account identification.
19548 /// - `supports_account_statement`: Filter only institutions which support
19549 /// account statements.
19550 /// - `supports_account_verification`: Filter only institutions which
19551 /// support account verification.
19552 /// - `supports_transaction_history`: Filter only institutions which support
19553 /// extended transaction history.
19554 pub async fn list_institutions<'a>(
19555 &'a self,
19556 iso_country_code: Option<&'a ::std::vec::Vec<::std::string::String>>,
19557 name: Option<&'a str>,
19558 page: Option<i64>,
19559 records_per_page: Option<i64>,
19560 supports_account_identification: Option<bool>,
19561 supports_account_statement: Option<bool>,
19562 supports_account_verification: Option<bool>,
19563 supports_transaction_history: Option<bool>,
19564 ) -> Result<ResponseValue<types::InstitutionsResponseBody>, Error<()>> {
19565 let url = format!("{}/institutions", self.baseurl,);
19566 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
19567 header_map.append(
19568 ::reqwest::header::HeaderName::from_static("api-version"),
19569 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
19570 );
19571 #[allow(unused_mut)]
19572 let mut request = self
19573 .client
19574 .get(url)
19575 .header(
19576 ::reqwest::header::ACCEPT,
19577 ::reqwest::header::HeaderValue::from_static("application/json"),
19578 )
19579 .query(&progenitor_client::QueryParam::new(
19580 "iso_country_code",
19581 &iso_country_code,
19582 ))
19583 .query(&progenitor_client::QueryParam::new("name", &name))
19584 .query(&progenitor_client::QueryParam::new("page", &page))
19585 .query(&progenitor_client::QueryParam::new(
19586 "records_per_page",
19587 &records_per_page,
19588 ))
19589 .query(&progenitor_client::QueryParam::new(
19590 "supports_account_identification",
19591 &supports_account_identification,
19592 ))
19593 .query(&progenitor_client::QueryParam::new(
19594 "supports_account_statement",
19595 &supports_account_statement,
19596 ))
19597 .query(&progenitor_client::QueryParam::new(
19598 "supports_account_verification",
19599 &supports_account_verification,
19600 ))
19601 .query(&progenitor_client::QueryParam::new(
19602 "supports_transaction_history",
19603 &supports_transaction_history,
19604 ))
19605 .headers(header_map)
19606 .build()?;
19607 let info = OperationInfo {
19608 operation_id: "list_institutions",
19609 };
19610 self.pre(&mut request, &info).await?;
19611 let result = self.exec(request, &info).await;
19612 self.post(&result, &info).await?;
19613 let response = result?;
19614 match response.status().as_u16() {
19615 200u16 => ResponseValue::from_response(response).await,
19616 _ => Err(Error::UnexpectedResponse(response)),
19617 }
19618 }
19619
19620 ///List favorite institutions
19621 ///
19622 ///This endpoint returns a paginated list containing institutions that have
19623 /// been set as the partner’s favorites, sorted by popularity. Please
19624 /// contact MX to set a list of favorites.
19625 ///
19626 ///Sends a `GET` request to `/institutions/favorites`
19627 ///
19628 ///Arguments:
19629 /// - `iso_country_code`: An array of strings that filters institutions in
19630 /// the widget by the specified country code. Acceptable codes include
19631 /// `US`, `CA`, and `MX` (Mexico).
19632 /// - `page`: Results are paginated. Specify current page.
19633 /// - `records_per_page`: This specifies the number of records to be
19634 /// returned on each page. Defaults to `25`. The valid range is from `10`
19635 /// to `100`. If the value exceeds `100`, the default value of `25` will
19636 /// be used instead.
19637 pub async fn list_favorite_institutions<'a>(
19638 &'a self,
19639 iso_country_code: Option<&'a ::std::vec::Vec<::std::string::String>>,
19640 page: Option<i64>,
19641 records_per_page: Option<i64>,
19642 ) -> Result<ResponseValue<types::InstitutionsResponseBody>, Error<()>> {
19643 let url = format!("{}/institutions/favorites", self.baseurl,);
19644 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
19645 header_map.append(
19646 ::reqwest::header::HeaderName::from_static("api-version"),
19647 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
19648 );
19649 #[allow(unused_mut)]
19650 let mut request = self
19651 .client
19652 .get(url)
19653 .header(
19654 ::reqwest::header::ACCEPT,
19655 ::reqwest::header::HeaderValue::from_static("application/json"),
19656 )
19657 .query(&progenitor_client::QueryParam::new(
19658 "iso_country_code",
19659 &iso_country_code,
19660 ))
19661 .query(&progenitor_client::QueryParam::new("page", &page))
19662 .query(&progenitor_client::QueryParam::new(
19663 "records_per_page",
19664 &records_per_page,
19665 ))
19666 .headers(header_map)
19667 .build()?;
19668 let info = OperationInfo {
19669 operation_id: "list_favorite_institutions",
19670 };
19671 self.pre(&mut request, &info).await?;
19672 let result = self.exec(request, &info).await;
19673 self.post(&result, &info).await?;
19674 let response = result?;
19675 match response.status().as_u16() {
19676 200u16 => ResponseValue::from_response(response).await,
19677 _ => Err(Error::UnexpectedResponse(response)),
19678 }
19679 }
19680
19681 ///Read institution
19682 ///
19683 ///This endpoint returns information about the institution specified by
19684 /// `institution_code`.
19685 ///
19686 ///Sends a `GET` request to `/institutions/{institution_code}`
19687 ///
19688 ///Arguments:
19689 /// - `institution_code`: The institution_code of the institution.
19690 pub async fn read_institution<'a>(
19691 &'a self,
19692 institution_code: &'a str,
19693 ) -> Result<ResponseValue<types::InstitutionResponseBody>, Error<()>> {
19694 let url = format!(
19695 "{}/institutions/{}",
19696 self.baseurl,
19697 encode_path(&institution_code.to_string()),
19698 );
19699 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
19700 header_map.append(
19701 ::reqwest::header::HeaderName::from_static("api-version"),
19702 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
19703 );
19704 #[allow(unused_mut)]
19705 let mut request = self
19706 .client
19707 .get(url)
19708 .header(
19709 ::reqwest::header::ACCEPT,
19710 ::reqwest::header::HeaderValue::from_static("application/json"),
19711 )
19712 .headers(header_map)
19713 .build()?;
19714 let info = OperationInfo {
19715 operation_id: "read_institution",
19716 };
19717 self.pre(&mut request, &info).await?;
19718 let result = self.exec(request, &info).await;
19719 self.post(&result, &info).await?;
19720 let response = result?;
19721 match response.status().as_u16() {
19722 200u16 => ResponseValue::from_response(response).await,
19723 _ => Err(Error::UnexpectedResponse(response)),
19724 }
19725 }
19726
19727 ///List institution credentials
19728 ///
19729 ///Use this endpoint to see which credentials will be needed to create a
19730 /// member for a specific institution.
19731 ///
19732 ///Passing an invalid `institution_code` returns a `404`.
19733 ///
19734 ///
19735 ///Sends a `GET` request to `/institutions/{institution_code}/credentials`
19736 ///
19737 ///Arguments:
19738 /// - `institution_code`: The institution_code of the institution.
19739 /// - `page`: Results are paginated. Specify current page.
19740 /// - `records_per_page`: This specifies the number of records to be
19741 /// returned on each page. Defaults to `25`. The valid range is from `10`
19742 /// to `1000`. If the value exceeds `1000`, the default value of `25` will
19743 /// be used instead.
19744 pub async fn list_institution_credentials<'a>(
19745 &'a self,
19746 institution_code: &'a str,
19747 page: Option<i64>,
19748 records_per_page: Option<i64>,
19749 ) -> Result<ResponseValue<types::CredentialsResponseBody>, Error<()>> {
19750 let url = format!(
19751 "{}/institutions/{}/credentials",
19752 self.baseurl,
19753 encode_path(&institution_code.to_string()),
19754 );
19755 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
19756 header_map.append(
19757 ::reqwest::header::HeaderName::from_static("api-version"),
19758 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
19759 );
19760 #[allow(unused_mut)]
19761 let mut request = self
19762 .client
19763 .get(url)
19764 .header(
19765 ::reqwest::header::ACCEPT,
19766 ::reqwest::header::HeaderValue::from_static("application/json"),
19767 )
19768 .query(&progenitor_client::QueryParam::new("page", &page))
19769 .query(&progenitor_client::QueryParam::new(
19770 "records_per_page",
19771 &records_per_page,
19772 ))
19773 .headers(header_map)
19774 .build()?;
19775 let info = OperationInfo {
19776 operation_id: "list_institution_credentials",
19777 };
19778 self.pre(&mut request, &info).await?;
19779 let result = self.exec(request, &info).await;
19780 self.post(&result, &info).await?;
19781 let response = result?;
19782 match response.status().as_u16() {
19783 200u16 => ResponseValue::from_response(response).await,
19784 _ => Err(Error::UnexpectedResponse(response)),
19785 }
19786 }
19787
19788 ///List managed institutions
19789 ///
19790 ///This endpoint returns a list of institutions which can be used to create
19791 /// partner-managed members.
19792 ///
19793 ///Sends a `GET` request to `/managed_institutions`
19794 ///
19795 ///Arguments:
19796 /// - `page`: Results are paginated. Specify current page.
19797 /// - `records_per_page`: This specifies the number of records to be
19798 /// returned on each page. Defaults to `25`. The valid range is from `10`
19799 /// to `1000`. If the value exceeds `1000`, the default value of `25` will
19800 /// be used instead.
19801 pub async fn list_managed_institutions<'a>(
19802 &'a self,
19803 page: Option<i64>,
19804 records_per_page: Option<i64>,
19805 ) -> Result<ResponseValue<types::InstitutionsResponseBody>, Error<()>> {
19806 let url = format!("{}/managed_institutions", self.baseurl,);
19807 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
19808 header_map.append(
19809 ::reqwest::header::HeaderName::from_static("api-version"),
19810 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
19811 );
19812 #[allow(unused_mut)]
19813 let mut request = self
19814 .client
19815 .get(url)
19816 .header(
19817 ::reqwest::header::ACCEPT,
19818 ::reqwest::header::HeaderValue::from_static("application/json"),
19819 )
19820 .query(&progenitor_client::QueryParam::new("page", &page))
19821 .query(&progenitor_client::QueryParam::new(
19822 "records_per_page",
19823 &records_per_page,
19824 ))
19825 .headers(header_map)
19826 .build()?;
19827 let info = OperationInfo {
19828 operation_id: "list_managed_institutions",
19829 };
19830 self.pre(&mut request, &info).await?;
19831 let result = self.exec(request, &info).await;
19832 self.post(&result, &info).await?;
19833 let response = result?;
19834 match response.status().as_u16() {
19835 200u16 => ResponseValue::from_response(response).await,
19836 _ => Err(Error::UnexpectedResponse(response)),
19837 }
19838 }
19839
19840 ///Read merchant location
19841 ///
19842 ///This endpoint returns the specified `merchant_location` resource. The
19843 /// `merchant_location_guid` can be found on `transaction` objects.
19844 ///
19845 ///Sends a `GET` request to `/merchant_locations/{merchant_location_guid}`
19846 ///
19847 ///Arguments:
19848 /// - `merchant_location_guid`: The unique id for a `merchant_location`.
19849 pub async fn read_merchant_location<'a>(
19850 &'a self,
19851 merchant_location_guid: &'a str,
19852 ) -> Result<ResponseValue<types::MerchantLocationResponseBody>, Error<()>> {
19853 let url = format!(
19854 "{}/merchant_locations/{}",
19855 self.baseurl,
19856 encode_path(&merchant_location_guid.to_string()),
19857 );
19858 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
19859 header_map.append(
19860 ::reqwest::header::HeaderName::from_static("api-version"),
19861 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
19862 );
19863 #[allow(unused_mut)]
19864 let mut request = self
19865 .client
19866 .get(url)
19867 .header(
19868 ::reqwest::header::ACCEPT,
19869 ::reqwest::header::HeaderValue::from_static("application/json"),
19870 )
19871 .headers(header_map)
19872 .build()?;
19873 let info = OperationInfo {
19874 operation_id: "read_merchant_location",
19875 };
19876 self.pre(&mut request, &info).await?;
19877 let result = self.exec(request, &info).await;
19878 self.post(&result, &info).await?;
19879 let response = result?;
19880 match response.status().as_u16() {
19881 200u16 => ResponseValue::from_response(response).await,
19882 _ => Err(Error::UnexpectedResponse(response)),
19883 }
19884 }
19885
19886 ///List merchants
19887 ///
19888 ///This endpoint returns a paginated list of all the merchants in the MX
19889 /// system.
19890 ///
19891 ///Sends a `GET` request to `/merchants`
19892 ///
19893 ///Arguments:
19894 /// - `name`: This will list only merchants in which the appended string
19895 /// appears.
19896 /// - `page`: Results are paginated. Specify current page.
19897 /// - `records_per_page`: This specifies the number of records to be
19898 /// returned on each page. Defaults to `25`. The valid range is from `10`
19899 /// to `1000`. If the value exceeds `1000`, the default value of `25` will
19900 /// be used instead.
19901 pub async fn list_merchants<'a>(
19902 &'a self,
19903 name: Option<&'a str>,
19904 page: Option<i64>,
19905 records_per_page: Option<i64>,
19906 ) -> Result<ResponseValue<types::MerchantsResponseBody>, Error<()>> {
19907 let url = format!("{}/merchants", self.baseurl,);
19908 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
19909 header_map.append(
19910 ::reqwest::header::HeaderName::from_static("api-version"),
19911 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
19912 );
19913 #[allow(unused_mut)]
19914 let mut request = self
19915 .client
19916 .get(url)
19917 .header(
19918 ::reqwest::header::ACCEPT,
19919 ::reqwest::header::HeaderValue::from_static("application/json"),
19920 )
19921 .query(&progenitor_client::QueryParam::new("name", &name))
19922 .query(&progenitor_client::QueryParam::new("page", &page))
19923 .query(&progenitor_client::QueryParam::new(
19924 "records_per_page",
19925 &records_per_page,
19926 ))
19927 .headers(header_map)
19928 .build()?;
19929 let info = OperationInfo {
19930 operation_id: "list_merchants",
19931 };
19932 self.pre(&mut request, &info).await?;
19933 let result = self.exec(request, &info).await;
19934 self.post(&result, &info).await?;
19935 let response = result?;
19936 match response.status().as_u16() {
19937 200u16 => ResponseValue::from_response(response).await,
19938 _ => Err(Error::UnexpectedResponse(response)),
19939 }
19940 }
19941
19942 ///Read merchant
19943 ///
19944 ///Returns information about a particular merchant, such as a logo, name,
19945 /// and website.
19946 ///
19947 ///Sends a `GET` request to `/merchants/{merchant_guid}`
19948 ///
19949 ///Arguments:
19950 /// - `merchant_guid`: The unique id for a `merchant`.
19951 pub async fn read_merchant<'a>(
19952 &'a self,
19953 merchant_guid: &'a str,
19954 ) -> Result<ResponseValue<types::MerchantResponseBody>, Error<()>> {
19955 let url = format!(
19956 "{}/merchants/{}",
19957 self.baseurl,
19958 encode_path(&merchant_guid.to_string()),
19959 );
19960 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
19961 header_map.append(
19962 ::reqwest::header::HeaderName::from_static("api-version"),
19963 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
19964 );
19965 #[allow(unused_mut)]
19966 let mut request = self
19967 .client
19968 .get(url)
19969 .header(
19970 ::reqwest::header::ACCEPT,
19971 ::reqwest::header::HeaderValue::from_static("application/json"),
19972 )
19973 .headers(header_map)
19974 .build()?;
19975 let info = OperationInfo {
19976 operation_id: "read_merchant",
19977 };
19978 self.pre(&mut request, &info).await?;
19979 let result = self.exec(request, &info).await;
19980 self.post(&result, &info).await?;
19981 let response = result?;
19982 match response.status().as_u16() {
19983 200u16 => ResponseValue::from_response(response).await,
19984 _ => Err(Error::UnexpectedResponse(response)),
19985 }
19986 }
19987
19988 ///(Deprecated) Request an authorization code
19989 ///
19990 ///(This endpoint is deprecated. Clients should use `/authorization_code`.)
19991 /// Clients use this endpoint to request an authorization_code according to
19992 /// a user, member, and account specified in the request body. Clients then
19993 /// pass this code to processors. Processor access is scoped only to the
19994 /// user/member/account specified in this request. Before requesting an
19995 /// authorization_code, clients must have verified the specified member.
19996 ///
19997 ///Sends a `POST` request to `/payment_processor_authorization_code`
19998 ///
19999 ///Arguments:
20000 /// - `body`: The scope for the authorization code.
20001 pub async fn deprecated_request_payment_processor_authorization_code<'a>(
20002 &'a self,
20003 body: &'a types::PaymentProcessorAuthorizationCodeRequestBody,
20004 ) -> Result<ResponseValue<types::PaymentProcessorAuthorizationCodeResponseBody>, Error<()>>
20005 {
20006 let url = format!("{}/payment_processor_authorization_code", self.baseurl,);
20007 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
20008 header_map.append(
20009 ::reqwest::header::HeaderName::from_static("api-version"),
20010 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
20011 );
20012 #[allow(unused_mut)]
20013 let mut request = self
20014 .client
20015 .post(url)
20016 .header(
20017 ::reqwest::header::ACCEPT,
20018 ::reqwest::header::HeaderValue::from_static("application/json"),
20019 )
20020 .json(&body)
20021 .headers(header_map)
20022 .build()?;
20023 let info = OperationInfo {
20024 operation_id: "deprecated_request_payment_processor_authorization_code",
20025 };
20026 self.pre(&mut request, &info).await?;
20027 let result = self.exec(request, &info).await;
20028 self.post(&result, &info).await?;
20029 let response = result?;
20030 match response.status().as_u16() {
20031 200u16 => ResponseValue::from_response(response).await,
20032 _ => Err(Error::UnexpectedResponse(response)),
20033 }
20034 }
20035
20036 ///Enhance transactions
20037 ///
20038 ///Use this endpoint to categorize, cleanse, and classify transactions.
20039 /// These transactions are not persisted or stored on the MX platform. <br
20040 /// /><br />For more information on returned data, please see the [Enhanced
20041 /// Transactions fields
20042 /// guide](/api-reference/platform-api/reference/transactions-overview#
20043 /// enhanced-transactions).
20044 ///
20045 ///Sends a `POST` request to `/transactions/enhance`
20046 ///
20047 ///Arguments:
20048 /// - `body`: Transaction object to be enhanced
20049 pub async fn enhance_transactions<'a>(
20050 &'a self,
20051 body: &'a types::EnhanceTransactionsRequestBody,
20052 ) -> Result<ResponseValue<types::EnhanceTransactionsResponseBody>, Error<()>> {
20053 let url = format!("{}/transactions/enhance", self.baseurl,);
20054 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
20055 header_map.append(
20056 ::reqwest::header::HeaderName::from_static("api-version"),
20057 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
20058 );
20059 #[allow(unused_mut)]
20060 let mut request = self
20061 .client
20062 .post(url)
20063 .header(
20064 ::reqwest::header::ACCEPT,
20065 ::reqwest::header::HeaderValue::from_static("application/json"),
20066 )
20067 .json(&body)
20068 .headers(header_map)
20069 .build()?;
20070 let info = OperationInfo {
20071 operation_id: "enhance_transactions",
20072 };
20073 self.pre(&mut request, &info).await?;
20074 let result = self.exec(request, &info).await;
20075 self.post(&result, &info).await?;
20076 let response = result?;
20077 match response.status().as_u16() {
20078 200u16 => ResponseValue::from_response(response).await,
20079 _ => Err(Error::UnexpectedResponse(response)),
20080 }
20081 }
20082
20083 ///List users
20084 ///
20085 ///Use this endpoint to list every user you've created in the MX Platform
20086 /// API.
20087 ///
20088 ///Sends a `GET` request to `/users`
20089 ///
20090 ///Arguments:
20091 /// - `email`: The user `email` to search for.
20092 /// - `id`: The user `id` to search for.
20093 /// - `is_disabled`: Search for users that are diabled.
20094 /// - `page`: Results are paginated. Specify current page.
20095 /// - `records_per_page`: This specifies the number of records to be
20096 /// returned on each page. Defaults to `25`. The valid range is from `10`
20097 /// to `1000`. If the value exceeds `1000`, the default value of `25` will
20098 /// be used instead.
20099 pub async fn list_users<'a>(
20100 &'a self,
20101 email: Option<&'a str>,
20102 id: Option<&'a str>,
20103 is_disabled: Option<bool>,
20104 page: Option<i64>,
20105 records_per_page: Option<i64>,
20106 ) -> Result<ResponseValue<types::UsersResponseBody>, Error<()>> {
20107 let url = format!("{}/users", self.baseurl,);
20108 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
20109 header_map.append(
20110 ::reqwest::header::HeaderName::from_static("api-version"),
20111 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
20112 );
20113 #[allow(unused_mut)]
20114 let mut request = self
20115 .client
20116 .get(url)
20117 .header(
20118 ::reqwest::header::ACCEPT,
20119 ::reqwest::header::HeaderValue::from_static("application/json"),
20120 )
20121 .query(&progenitor_client::QueryParam::new("email", &email))
20122 .query(&progenitor_client::QueryParam::new("id", &id))
20123 .query(&progenitor_client::QueryParam::new(
20124 "is_disabled",
20125 &is_disabled,
20126 ))
20127 .query(&progenitor_client::QueryParam::new("page", &page))
20128 .query(&progenitor_client::QueryParam::new(
20129 "records_per_page",
20130 &records_per_page,
20131 ))
20132 .headers(header_map)
20133 .build()?;
20134 let info = OperationInfo {
20135 operation_id: "list_users",
20136 };
20137 self.pre(&mut request, &info).await?;
20138 let result = self.exec(request, &info).await;
20139 self.post(&result, &info).await?;
20140 let response = result?;
20141 match response.status().as_u16() {
20142 200u16 => ResponseValue::from_response(response).await,
20143 _ => Err(Error::UnexpectedResponse(response)),
20144 }
20145 }
20146
20147 ///Create user
20148 ///
20149 ///Use this endpoint to create a new user. The API will respond with the
20150 /// newly-created user object if successful, containing a `guid` that you'll
20151 /// set as the `user_guid` in other requests when required. Disabling a user
20152 /// means that accounts and transactions associated with it will not be
20153 /// updated in the background by MX. It will also restrict access to that
20154 /// user’s data until they are no longer disabled.
20155 ///
20156 ///Sends a `POST` request to `/users`
20157 ///
20158 ///Arguments:
20159 /// - `body`: User object to be created. (None of these parameters are
20160 /// required, but the user object cannot be empty)
20161 pub async fn create_user<'a>(
20162 &'a self,
20163 body: &'a types::UserCreateRequestBody,
20164 ) -> Result<ResponseValue<types::UserResponseBody>, Error<()>> {
20165 let url = format!("{}/users", self.baseurl,);
20166 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
20167 header_map.append(
20168 ::reqwest::header::HeaderName::from_static("api-version"),
20169 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
20170 );
20171 #[allow(unused_mut)]
20172 let mut request = self
20173 .client
20174 .post(url)
20175 .header(
20176 ::reqwest::header::ACCEPT,
20177 ::reqwest::header::HeaderValue::from_static("application/json"),
20178 )
20179 .json(&body)
20180 .headers(header_map)
20181 .build()?;
20182 let info = OperationInfo {
20183 operation_id: "create_user",
20184 };
20185 self.pre(&mut request, &info).await?;
20186 let result = self.exec(request, &info).await;
20187 self.post(&result, &info).await?;
20188 let response = result?;
20189 match response.status().as_u16() {
20190 200u16 => ResponseValue::from_response(response).await,
20191 _ => Err(Error::UnexpectedResponse(response)),
20192 }
20193 }
20194
20195 ///Read user
20196 ///
20197 ///Use this endpoint to read the attributes of a specific user.
20198 ///
20199 ///Sends a `GET` request to `/users/{user_guid}`
20200 ///
20201 ///Arguments:
20202 /// - `user_guid`: The unique identifier for a `user`, beginning with the
20203 /// prefix `USR-`.
20204 pub async fn read_user<'a>(
20205 &'a self,
20206 user_guid: &'a str,
20207 ) -> Result<ResponseValue<types::UserResponseBody>, Error<()>> {
20208 let url = format!(
20209 "{}/users/{}",
20210 self.baseurl,
20211 encode_path(&user_guid.to_string()),
20212 );
20213 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
20214 header_map.append(
20215 ::reqwest::header::HeaderName::from_static("api-version"),
20216 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
20217 );
20218 #[allow(unused_mut)]
20219 let mut request = self
20220 .client
20221 .get(url)
20222 .header(
20223 ::reqwest::header::ACCEPT,
20224 ::reqwest::header::HeaderValue::from_static("application/json"),
20225 )
20226 .headers(header_map)
20227 .build()?;
20228 let info = OperationInfo {
20229 operation_id: "read_user",
20230 };
20231 self.pre(&mut request, &info).await?;
20232 let result = self.exec(request, &info).await;
20233 self.post(&result, &info).await?;
20234 let response = result?;
20235 match response.status().as_u16() {
20236 200u16 => ResponseValue::from_response(response).await,
20237 _ => Err(Error::UnexpectedResponse(response)),
20238 }
20239 }
20240
20241 ///Update user
20242 ///
20243 ///Use this endpoint to update the attributes of the specified user.
20244 ///
20245 ///Sends a `PUT` request to `/users/{user_guid}`
20246 ///
20247 ///Arguments:
20248 /// - `user_guid`: The unique identifier for a `user`, beginning with the
20249 /// prefix `USR-`.
20250 /// - `body`: User object to be updated (None of these parameters are
20251 /// required, but the user object cannot be empty.)
20252 pub async fn update_user<'a>(
20253 &'a self,
20254 user_guid: &'a str,
20255 body: &'a types::UserUpdateRequestBody,
20256 ) -> Result<ResponseValue<types::UserResponseBody>, Error<()>> {
20257 let url = format!(
20258 "{}/users/{}",
20259 self.baseurl,
20260 encode_path(&user_guid.to_string()),
20261 );
20262 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
20263 header_map.append(
20264 ::reqwest::header::HeaderName::from_static("api-version"),
20265 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
20266 );
20267 #[allow(unused_mut)]
20268 let mut request = self
20269 .client
20270 .put(url)
20271 .header(
20272 ::reqwest::header::ACCEPT,
20273 ::reqwest::header::HeaderValue::from_static("application/json"),
20274 )
20275 .json(&body)
20276 .headers(header_map)
20277 .build()?;
20278 let info = OperationInfo {
20279 operation_id: "update_user",
20280 };
20281 self.pre(&mut request, &info).await?;
20282 let result = self.exec(request, &info).await;
20283 self.post(&result, &info).await?;
20284 let response = result?;
20285 match response.status().as_u16() {
20286 200u16 => ResponseValue::from_response(response).await,
20287 _ => Err(Error::UnexpectedResponse(response)),
20288 }
20289 }
20290
20291 ///Delete user
20292 ///
20293 ///Use this endpoint to delete the specified `user`. The response will have
20294 /// a status of `204 No Content` without an object.
20295 ///
20296 ///:::warning
20297 ///Deleting a user is permanent. Deleted users can never be restored. For more info, see [Deleting Objects](https://docs.mx.com/api-reference/platform-api/overview/deleting-objects).
20298 ///:::
20299 ///
20300 ///
20301 ///Sends a `DELETE` request to `/users/{user_guid}`
20302 ///
20303 ///Arguments:
20304 /// - `user_guid`: The unique identifier for a `user`, beginning with the
20305 /// prefix `USR-`.
20306 /// - `accept`: Specifies the media type expected in the response.
20307 pub async fn delete_user<'a>(
20308 &'a self,
20309 user_guid: &'a str,
20310 accept: &'a str,
20311 ) -> Result<ResponseValue<()>, Error<()>> {
20312 let url = format!(
20313 "{}/users/{}",
20314 self.baseurl,
20315 encode_path(&user_guid.to_string()),
20316 );
20317 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(2usize);
20318 header_map.append(
20319 ::reqwest::header::HeaderName::from_static("api-version"),
20320 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
20321 );
20322 header_map.append("Accept", accept.to_string().try_into()?);
20323 #[allow(unused_mut)]
20324 let mut request = self.client.delete(url).headers(header_map).build()?;
20325 let info = OperationInfo {
20326 operation_id: "delete_user",
20327 };
20328 self.pre(&mut request, &info).await?;
20329 let result = self.exec(request, &info).await;
20330 self.post(&result, &info).await?;
20331 let response = result?;
20332 match response.status().as_u16() {
20333 204u16 => Ok(ResponseValue::empty(response)),
20334 _ => Err(Error::UnexpectedResponse(response)),
20335 }
20336 }
20337
20338 ///List accounts
20339 ///
20340 ///This endpoint returns a list of all the accounts associated with the
20341 /// specified `user`.
20342 ///
20343 ///:::warning
20344 ///This request will not return the full account number. It may return the last four digits of the account number if that information has been provided during aggregation. If you need the full account number, please refer to [List account numbers by member](https://docs.mx.com/api-reference/platform-api/reference/list-account-numbers-by-member/), [List account numbers by account](https://docs.mx.com/api-reference/platform-api/reference/list-account-numbers-by-account/), or the [Fetch Account and Routing Numbers](https://docs.mx.com/products/connectivity/instant-account-verification/fetch-account-routing-number-api/#4-read-the-account-numbers) guide.
20345 ///:::
20346 ///
20347 ///
20348 ///Sends a `GET` request to `/users/{user_guid}/accounts`
20349 ///
20350 ///Arguments:
20351 /// - `user_guid`: The unique identifier for a `user`, beginning with the
20352 /// prefix `USR-`.
20353 /// - `is_manual`: List only accounts that were manually created.
20354 /// - `member_is_managed_by_user`: List only accounts whose member is
20355 /// managed by the user.
20356 /// - `page`: Results are paginated. Specify current page.
20357 /// - `records_per_page`: This specifies the number of records to be
20358 /// returned on each page. Defaults to `25`. The valid range is from `10`
20359 /// to `1000`. If the value exceeds `1000`, the default value of `25` will
20360 /// be used instead.
20361 /// - `use_case`: The use case associated with the member. Valid values are
20362 /// `PFM` and `MONEY_MOVEMENT`. For example, you can append either
20363 /// `?use_case=PFM` or `?use_case=MONEY_MOVEMENT`.
20364 pub async fn list_user_accounts<'a>(
20365 &'a self,
20366 user_guid: &'a str,
20367 is_manual: Option<bool>,
20368 member_is_managed_by_user: Option<bool>,
20369 page: Option<i64>,
20370 records_per_page: Option<i64>,
20371 use_case: Option<&'a str>,
20372 ) -> Result<ResponseValue<types::AccountsResponseBody>, Error<()>> {
20373 let url = format!(
20374 "{}/users/{}/accounts",
20375 self.baseurl,
20376 encode_path(&user_guid.to_string()),
20377 );
20378 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
20379 header_map.append(
20380 ::reqwest::header::HeaderName::from_static("api-version"),
20381 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
20382 );
20383 #[allow(unused_mut)]
20384 let mut request = self
20385 .client
20386 .get(url)
20387 .header(
20388 ::reqwest::header::ACCEPT,
20389 ::reqwest::header::HeaderValue::from_static("application/json"),
20390 )
20391 .query(&progenitor_client::QueryParam::new("is_manual", &is_manual))
20392 .query(&progenitor_client::QueryParam::new(
20393 "member_is_managed_by_user",
20394 &member_is_managed_by_user,
20395 ))
20396 .query(&progenitor_client::QueryParam::new("page", &page))
20397 .query(&progenitor_client::QueryParam::new(
20398 "records_per_page",
20399 &records_per_page,
20400 ))
20401 .query(&progenitor_client::QueryParam::new("use_case", &use_case))
20402 .headers(header_map)
20403 .build()?;
20404 let info = OperationInfo {
20405 operation_id: "list_user_accounts",
20406 };
20407 self.pre(&mut request, &info).await?;
20408 let result = self.exec(request, &info).await;
20409 self.post(&result, &info).await?;
20410 let response = result?;
20411 match response.status().as_u16() {
20412 200u16 => ResponseValue::from_response(response).await,
20413 _ => Err(Error::UnexpectedResponse(response)),
20414 }
20415 }
20416
20417 ///Create manual account
20418 ///
20419 ///This endpoint can only be used to create manual accounts. Creating a
20420 /// manual account will automatically create it under the Manual Institution
20421 /// member. Since a manual account has no credentials tied to the member,
20422 /// the account will never aggregate or include data from a data feed..
20423 ///
20424 ///Sends a `POST` request to `/users/{user_guid}/accounts`
20425 ///
20426 ///Arguments:
20427 /// - `user_guid`: The unique identifier for a `user`, beginning with the
20428 /// prefix `USR-`.
20429 /// - `body`: Manual account object to be created.
20430 pub async fn create_manual_account<'a>(
20431 &'a self,
20432 user_guid: &'a str,
20433 body: &'a types::AccountCreateRequestBody,
20434 ) -> Result<ResponseValue<types::AccountResponseBody>, Error<()>> {
20435 let url = format!(
20436 "{}/users/{}/accounts",
20437 self.baseurl,
20438 encode_path(&user_guid.to_string()),
20439 );
20440 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
20441 header_map.append(
20442 ::reqwest::header::HeaderName::from_static("api-version"),
20443 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
20444 );
20445 #[allow(unused_mut)]
20446 let mut request = self
20447 .client
20448 .post(url)
20449 .header(
20450 ::reqwest::header::ACCEPT,
20451 ::reqwest::header::HeaderValue::from_static("application/json"),
20452 )
20453 .json(&body)
20454 .headers(header_map)
20455 .build()?;
20456 let info = OperationInfo {
20457 operation_id: "create_manual_account",
20458 };
20459 self.pre(&mut request, &info).await?;
20460 let result = self.exec(request, &info).await;
20461 self.post(&result, &info).await?;
20462 let response = result?;
20463 match response.status().as_u16() {
20464 200u16 => ResponseValue::from_response(response).await,
20465 _ => Err(Error::UnexpectedResponse(response)),
20466 }
20467 }
20468
20469 ///Read account
20470 ///
20471 ///This endpoint returns the specified `account` resource.
20472 ///
20473 ///Sends a `GET` request to `/users/{user_guid}/accounts/{account_guid}`
20474 ///
20475 ///Arguments:
20476 /// - `user_guid`: The unique identifier for a `user`, beginning with the
20477 /// prefix `USR-`.
20478 /// - `account_guid`: The unique id for an `account`.
20479 pub async fn read_account<'a>(
20480 &'a self,
20481 user_guid: &'a str,
20482 account_guid: &'a str,
20483 ) -> Result<ResponseValue<types::AccountResponseBody>, Error<()>> {
20484 let url = format!(
20485 "{}/users/{}/accounts/{}",
20486 self.baseurl,
20487 encode_path(&user_guid.to_string()),
20488 encode_path(&account_guid.to_string()),
20489 );
20490 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
20491 header_map.append(
20492 ::reqwest::header::HeaderName::from_static("api-version"),
20493 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
20494 );
20495 #[allow(unused_mut)]
20496 let mut request = self
20497 .client
20498 .get(url)
20499 .header(
20500 ::reqwest::header::ACCEPT,
20501 ::reqwest::header::HeaderValue::from_static("application/json"),
20502 )
20503 .headers(header_map)
20504 .build()?;
20505 let info = OperationInfo {
20506 operation_id: "read_account",
20507 };
20508 self.pre(&mut request, &info).await?;
20509 let result = self.exec(request, &info).await;
20510 self.post(&result, &info).await?;
20511 let response = result?;
20512 match response.status().as_u16() {
20513 200u16 => ResponseValue::from_response(response).await,
20514 _ => Err(Error::UnexpectedResponse(response)),
20515 }
20516 }
20517
20518 ///Delete manual account
20519 ///
20520 ///This endpoint deletes accounts that were manually created. The API will
20521 /// respond with an empty object and a status of `204 No Content`.
20522 ///
20523 ///Sends a `DELETE` request to `/users/{user_guid}/accounts/{account_guid}`
20524 ///
20525 ///Arguments:
20526 /// - `user_guid`: The unique identifier for a `user`, beginning with the
20527 /// prefix `USR-`.
20528 /// - `account_guid`: The unique id for an `account`.
20529 /// - `accept`: Specifies the media type expected in the response.
20530 pub async fn delete_manual_account<'a>(
20531 &'a self,
20532 user_guid: &'a str,
20533 account_guid: &'a str,
20534 accept: &'a str,
20535 ) -> Result<ResponseValue<()>, Error<()>> {
20536 let url = format!(
20537 "{}/users/{}/accounts/{}",
20538 self.baseurl,
20539 encode_path(&user_guid.to_string()),
20540 encode_path(&account_guid.to_string()),
20541 );
20542 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(2usize);
20543 header_map.append(
20544 ::reqwest::header::HeaderName::from_static("api-version"),
20545 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
20546 );
20547 header_map.append("Accept", accept.to_string().try_into()?);
20548 #[allow(unused_mut)]
20549 let mut request = self.client.delete(url).headers(header_map).build()?;
20550 let info = OperationInfo {
20551 operation_id: "delete_manual_account",
20552 };
20553 self.pre(&mut request, &info).await?;
20554 let result = self.exec(request, &info).await;
20555 self.post(&result, &info).await?;
20556 let response = result?;
20557 match response.status().as_u16() {
20558 204u16 => Ok(ResponseValue::empty(response)),
20559 _ => Err(Error::UnexpectedResponse(response)),
20560 }
20561 }
20562
20563 ///List account numbers by account
20564 ///
20565 ///This endpoint returns a list of account numbers associated with the
20566 /// specified `account`.
20567 ///
20568 ///Sends a `GET` request to
20569 /// `/users/{user_guid}/accounts/{account_guid}/account_numbers`
20570 ///
20571 ///Arguments:
20572 /// - `user_guid`: The unique identifier for a `user`, beginning with the
20573 /// prefix `USR-`.
20574 /// - `account_guid`: The unique id for an `account`.
20575 /// - `page`: Results are paginated. Specify current page.
20576 /// - `records_per_page`: This specifies the number of records to be
20577 /// returned on each page. Defaults to `25`. The valid range is from `10`
20578 /// to `1000`. If the value exceeds `1000`, the default value of `25` will
20579 /// be used instead.
20580 pub async fn list_account_numbers_by_account<'a>(
20581 &'a self,
20582 user_guid: &'a str,
20583 account_guid: &'a str,
20584 page: Option<i64>,
20585 records_per_page: Option<i64>,
20586 ) -> Result<ResponseValue<types::AccountNumbersResponseBody>, Error<()>> {
20587 let url = format!(
20588 "{}/users/{}/accounts/{}/account_numbers",
20589 self.baseurl,
20590 encode_path(&user_guid.to_string()),
20591 encode_path(&account_guid.to_string()),
20592 );
20593 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
20594 header_map.append(
20595 ::reqwest::header::HeaderName::from_static("api-version"),
20596 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
20597 );
20598 #[allow(unused_mut)]
20599 let mut request = self
20600 .client
20601 .get(url)
20602 .header(
20603 ::reqwest::header::ACCEPT,
20604 ::reqwest::header::HeaderValue::from_static("application/json"),
20605 )
20606 .query(&progenitor_client::QueryParam::new("page", &page))
20607 .query(&progenitor_client::QueryParam::new(
20608 "records_per_page",
20609 &records_per_page,
20610 ))
20611 .headers(header_map)
20612 .build()?;
20613 let info = OperationInfo {
20614 operation_id: "list_account_numbers_by_account",
20615 };
20616 self.pre(&mut request, &info).await?;
20617 let result = self.exec(request, &info).await;
20618 self.post(&result, &info).await?;
20619 let response = result?;
20620 match response.status().as_u16() {
20621 200u16 => ResponseValue::from_response(response).await,
20622 _ => Err(Error::UnexpectedResponse(response)),
20623 }
20624 }
20625
20626 ///List insights by account
20627 ///
20628 ///Use this endpoint to list all insights associated with an account GUID.
20629 ///
20630 ///Sends a `GET` request to
20631 /// `/users/{user_guid}/accounts/{account_guid}/insights`
20632 ///
20633 ///Arguments:
20634 /// - `user_guid`: The unique identifier for a `user`, beginning with the
20635 /// prefix `USR-`.
20636 /// - `account_guid`: The unique id for an `account`.
20637 /// - `page`: Results are paginated. Specify current page.
20638 /// - `records_per_page`: This specifies the number of records to be
20639 /// returned on each page. Defaults to `25`. The valid range is from `10`
20640 /// to `100`. If the value exceeds `100`, the default value of `25` will
20641 /// be used instead.
20642 pub async fn list_insights_by_account<'a>(
20643 &'a self,
20644 user_guid: &'a str,
20645 account_guid: &'a str,
20646 page: Option<i64>,
20647 records_per_page: Option<i64>,
20648 ) -> Result<ResponseValue<types::InsightsResponseBody>, Error<()>> {
20649 let url = format!(
20650 "{}/users/{}/accounts/{}/insights",
20651 self.baseurl,
20652 encode_path(&user_guid.to_string()),
20653 encode_path(&account_guid.to_string()),
20654 );
20655 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
20656 header_map.append(
20657 ::reqwest::header::HeaderName::from_static("api-version"),
20658 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
20659 );
20660 #[allow(unused_mut)]
20661 let mut request = self
20662 .client
20663 .get(url)
20664 .header(
20665 ::reqwest::header::ACCEPT,
20666 ::reqwest::header::HeaderValue::from_static("application/json"),
20667 )
20668 .query(&progenitor_client::QueryParam::new("page", &page))
20669 .query(&progenitor_client::QueryParam::new(
20670 "records_per_page",
20671 &records_per_page,
20672 ))
20673 .headers(header_map)
20674 .build()?;
20675 let info = OperationInfo {
20676 operation_id: "list_insights_by_account",
20677 };
20678 self.pre(&mut request, &info).await?;
20679 let result = self.exec(request, &info).await;
20680 self.post(&result, &info).await?;
20681 let response = result?;
20682 match response.status().as_u16() {
20683 200u16 => ResponseValue::from_response(response).await,
20684 _ => Err(Error::UnexpectedResponse(response)),
20685 }
20686 }
20687
20688 ///List transactions by account
20689 ///
20690 ///Requests to this endpoint return a list of transactions associated with
20691 /// the specified account. <br /><br />Enhanced transaction data may be
20692 /// requested using the `includes` parameter. To use this optional
20693 /// parameter, the value should include the optional metadata requested such
20694 /// as `repeating_transactions`, `merchants`, `classifications`,
20695 /// `geolocations`. For more information, see the [Optional Enhancement
20696 /// Query Parameter
20697 /// guide](/api-reference/platform-api/reference/transactions-overview#
20698 /// enhanced-transactions#optional-enhancement-query-parameter).
20699 ///
20700 ///Sends a `GET` request to
20701 /// `/users/{user_guid}/accounts/{account_guid}/transactions`
20702 ///
20703 ///Arguments:
20704 /// - `user_guid`: The unique identifier for a `user`, beginning with the
20705 /// prefix `USR-`.
20706 /// - `account_guid`: The unique id for an `account`.
20707 /// - `category_guid`: Filter transactions belonging to specified
20708 /// `category_guid`.
20709 ///
20710 ///For example, `?category_guid=CAT-7829f71c-2e8c-afa5-2f55-fa3634b89874`.
20711 /// - `category_guid`: Filter transactions belonging to any specified
20712 /// `category_guid[]` in url.
20713 ///
20714 ///For example,
20715 /// `?category_guid[]=CAT-7829f71c-2e8c-afa5-2f55-fa3634b89874`.
20716 /// - `from_created_at`: Filter transactions from the date the transaction
20717 /// was created. This only supports ISO 8601 format without timestamp
20718 /// (YYYY-MM-DD). Maximum date range limit is 6 months.
20719 /// - `from_date`: Filter transactions from this date. This only supports
20720 /// ISO 8601 format without timestamp (YYYY-MM-DD). Defaults to 120 days
20721 /// ago if not provided.
20722 /// - `from_updated_at`: Filter transactions from the date in which the
20723 /// transaction was updated. This only supports ISO 8601 format without
20724 /// timestamp (YYYY-MM-DD). Maximum date range limit is 6 months.
20725 /// - `includes`: Options for enhanced transactions. This query parameter is
20726 /// optional. Possible additional metadata: `repeating_transactions`,
20727 /// `merchants`, `classifications`, `geolocations`. The query value is
20728 /// format sensitive. To retrieve all available enhancements, append:
20729 ///
20730 ///`?includes=repeating_transactions,merchants,classifications,
20731 /// geolocations`.
20732 ///
20733 ///The query options may be combined to specific enhancements. For example,
20734 /// to request Repeating Transactions and Geolocation data, use:
20735 ///
20736 ///`?includes=repeating_transactions,geolocations`.
20737 ///
20738 /// - Repeating Transactions: Identifies transactions with predictable
20739 /// recurrence patterns (e.g., Bill, Income, Subscription).
20740 /// - Merchants: Enriches transactions with merchant name.
20741 /// - Classifications: Provides more insight into the type of money movement
20742 /// that is occurring on the transaction, whether it be retail or
20743 /// investments.
20744 /// - Geolocation: Provides geographic metadata.
20745 ///
20746 /// - `page`: Results are paginated. Specify current page.
20747 /// - `records_per_page`: This specifies the number of records to be
20748 /// returned on each page. Defaults to `25`. The valid range is from `10`
20749 /// to `1000`. If the value exceeds `1000`, the default value of `25` will
20750 /// be used instead.
20751 /// - `to_created_at`: Filter transaction to the date in which the
20752 /// transaction was created. This only supports ISO 8601 format without
20753 /// timestamp (YYYY-MM-DD). Maximum date range limit is 6 months.
20754 /// - `to_date`: Filter transactions to this date (at midnight). This only
20755 /// supports ISO 8601 format without timestamp (YYYY-MM-DD). Defaults to 5
20756 /// days forward from the day the request is made to capture pending
20757 /// transactions.
20758 /// - `to_updated_at`: Filter transactions to the date in which the
20759 /// transaction was updated. This only supports ISO 8601 format without
20760 /// timestamp (YYYY-MM-DD). Maximum date range limit is 6 months.
20761 /// - `top_level_category_guid`: Filter transactions belonging to specified
20762 /// `top_level_category_guid`. This must be top level category guid, use
20763 /// `category_guid` for subcategory guid.
20764 ///
20765 ///For example,
20766 /// `?top_level_category_guid=CAT-7829f71c-2e8c-afa5-2f55-fa3634b89874`.
20767 /// - `top_level_category_guid`: Filter transactions belonging to any
20768 /// specified `top_level_category_guid[]` in url. This must be top level
20769 /// category guid(s), use `category_guid` for subcategory guid(s).
20770 ///
20771 ///For example,
20772 /// `?top_level_category_guid[]=CAT-7829f71c-2e8c-afa5-2f55-fa3634b89874`.
20773 pub async fn list_transactions_by_account<'a>(
20774 &'a self,
20775 user_guid: &'a str,
20776 account_guid: &'a str,
20777 category_guid: Option<&'a str>,
20778 from_created_at: Option<&'a str>,
20779 from_date: Option<&'a str>,
20780 from_updated_at: Option<&'a str>,
20781 includes: Option<&'a str>,
20782 page: Option<i64>,
20783 records_per_page: Option<i64>,
20784 to_created_at: Option<&'a str>,
20785 to_date: Option<&'a str>,
20786 to_updated_at: Option<&'a str>,
20787 top_level_category_guid: Option<&'a str>,
20788 ) -> Result<ResponseValue<types::TransactionsResponseBodyIncludes>, Error<()>> {
20789 let url = format!(
20790 "{}/users/{}/accounts/{}/transactions",
20791 self.baseurl,
20792 encode_path(&user_guid.to_string()),
20793 encode_path(&account_guid.to_string()),
20794 );
20795 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
20796 header_map.append(
20797 ::reqwest::header::HeaderName::from_static("api-version"),
20798 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
20799 );
20800 #[allow(unused_mut)]
20801 let mut request = self
20802 .client
20803 .get(url)
20804 .header(
20805 ::reqwest::header::ACCEPT,
20806 ::reqwest::header::HeaderValue::from_static("application/json"),
20807 )
20808 .query(&progenitor_client::QueryParam::new(
20809 "category_guid",
20810 &category_guid,
20811 ))
20812 .query(&progenitor_client::QueryParam::new(
20813 "category_guid[]",
20814 &category_guid,
20815 ))
20816 .query(&progenitor_client::QueryParam::new(
20817 "from_created_at",
20818 &from_created_at,
20819 ))
20820 .query(&progenitor_client::QueryParam::new("from_date", &from_date))
20821 .query(&progenitor_client::QueryParam::new(
20822 "from_updated_at",
20823 &from_updated_at,
20824 ))
20825 .query(&progenitor_client::QueryParam::new("includes", &includes))
20826 .query(&progenitor_client::QueryParam::new("page", &page))
20827 .query(&progenitor_client::QueryParam::new(
20828 "records_per_page",
20829 &records_per_page,
20830 ))
20831 .query(&progenitor_client::QueryParam::new(
20832 "to_created_at",
20833 &to_created_at,
20834 ))
20835 .query(&progenitor_client::QueryParam::new("to_date", &to_date))
20836 .query(&progenitor_client::QueryParam::new(
20837 "to_updated_at",
20838 &to_updated_at,
20839 ))
20840 .query(&progenitor_client::QueryParam::new(
20841 "top_level_category_guid",
20842 &top_level_category_guid,
20843 ))
20844 .query(&progenitor_client::QueryParam::new(
20845 "top_level_category_guid[]",
20846 &top_level_category_guid,
20847 ))
20848 .headers(header_map)
20849 .build()?;
20850 let info = OperationInfo {
20851 operation_id: "list_transactions_by_account",
20852 };
20853 self.pre(&mut request, &info).await?;
20854 let result = self.exec(request, &info).await;
20855 self.post(&result, &info).await?;
20856 let response = result?;
20857 match response.status().as_u16() {
20858 200u16 => ResponseValue::from_response(response).await,
20859 _ => Err(Error::UnexpectedResponse(response)),
20860 }
20861 }
20862
20863 ///Create manual transaction
20864 ///
20865 ///This endpoint can only be used to create manual transactions that are
20866 /// under a manual account. This endpoint accepts the optional
20867 /// MX-Skip-Webhook header and skip_webhook parameter.
20868 ///
20869 ///Sends a `POST` request to
20870 /// `/users/{user_guid}/accounts/{account_guid}/transactions`
20871 ///
20872 ///Arguments:
20873 /// - `user_guid`: The unique identifier for a `user`, beginning with the
20874 /// prefix `USR-`.
20875 /// - `account_guid`: The unique id for an `account`.
20876 /// - `body`
20877 pub async fn create_manual_transaction<'a>(
20878 &'a self,
20879 user_guid: &'a str,
20880 account_guid: &'a str,
20881 body: &'a types::TransactionCreateRequestBody,
20882 ) -> Result<ResponseValue<types::TransactionCreateResponseBody>, Error<()>> {
20883 let url = format!(
20884 "{}/users/{}/accounts/{}/transactions",
20885 self.baseurl,
20886 encode_path(&user_guid.to_string()),
20887 encode_path(&account_guid.to_string()),
20888 );
20889 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
20890 header_map.append(
20891 ::reqwest::header::HeaderName::from_static("api-version"),
20892 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
20893 );
20894 #[allow(unused_mut)]
20895 let mut request = self
20896 .client
20897 .post(url)
20898 .header(
20899 ::reqwest::header::ACCEPT,
20900 ::reqwest::header::HeaderValue::from_static("application/json"),
20901 )
20902 .json(&body)
20903 .headers(header_map)
20904 .build()?;
20905 let info = OperationInfo {
20906 operation_id: "create_manual_transaction",
20907 };
20908 self.pre(&mut request, &info).await?;
20909 let result = self.exec(request, &info).await;
20910 self.post(&result, &info).await?;
20911 let response = result?;
20912 match response.status().as_u16() {
20913 200u16 => ResponseValue::from_response(response).await,
20914 _ => Err(Error::UnexpectedResponse(response)),
20915 }
20916 }
20917
20918 ///List categories
20919 ///
20920 ///Use this endpoint to list all categories associated with a `user`,
20921 /// including both default and custom categories.
20922 ///
20923 ///Sends a `GET` request to `/users/{user_guid}/categories`
20924 ///
20925 ///Arguments:
20926 /// - `user_guid`: The unique identifier for a `user`, beginning with the
20927 /// prefix `USR-`.
20928 /// - `page`: Results are paginated. Specify current page.
20929 /// - `records_per_page`: This specifies the number of records to be
20930 /// returned on each page. Defaults to `25`. The valid range is from `10`
20931 /// to `1000`. If the value exceeds `1000`, the default value of `25` will
20932 /// be used instead.
20933 pub async fn list_categories<'a>(
20934 &'a self,
20935 user_guid: &'a str,
20936 page: Option<i64>,
20937 records_per_page: Option<i64>,
20938 ) -> Result<ResponseValue<types::CategoriesResponseBody>, Error<()>> {
20939 let url = format!(
20940 "{}/users/{}/categories",
20941 self.baseurl,
20942 encode_path(&user_guid.to_string()),
20943 );
20944 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
20945 header_map.append(
20946 ::reqwest::header::HeaderName::from_static("api-version"),
20947 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
20948 );
20949 #[allow(unused_mut)]
20950 let mut request = self
20951 .client
20952 .get(url)
20953 .header(
20954 ::reqwest::header::ACCEPT,
20955 ::reqwest::header::HeaderValue::from_static("application/json"),
20956 )
20957 .query(&progenitor_client::QueryParam::new("page", &page))
20958 .query(&progenitor_client::QueryParam::new(
20959 "records_per_page",
20960 &records_per_page,
20961 ))
20962 .headers(header_map)
20963 .build()?;
20964 let info = OperationInfo {
20965 operation_id: "list_categories",
20966 };
20967 self.pre(&mut request, &info).await?;
20968 let result = self.exec(request, &info).await;
20969 self.post(&result, &info).await?;
20970 let response = result?;
20971 match response.status().as_u16() {
20972 200u16 => ResponseValue::from_response(response).await,
20973 _ => Err(Error::UnexpectedResponse(response)),
20974 }
20975 }
20976
20977 ///Create category
20978 ///
20979 ///Use this endpoint to create a new custom category for a specific `user`.
20980 ///
20981 ///Sends a `POST` request to `/users/{user_guid}/categories`
20982 ///
20983 ///Arguments:
20984 /// - `user_guid`: The unique identifier for a `user`, beginning with the
20985 /// prefix `USR-`.
20986 /// - `body`: Custom category object to be created
20987 pub async fn create_category<'a>(
20988 &'a self,
20989 user_guid: &'a str,
20990 body: &'a types::CategoryCreateRequestBody,
20991 ) -> Result<ResponseValue<types::CategoryResponseBody>, Error<()>> {
20992 let url = format!(
20993 "{}/users/{}/categories",
20994 self.baseurl,
20995 encode_path(&user_guid.to_string()),
20996 );
20997 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
20998 header_map.append(
20999 ::reqwest::header::HeaderName::from_static("api-version"),
21000 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
21001 );
21002 #[allow(unused_mut)]
21003 let mut request = self
21004 .client
21005 .post(url)
21006 .header(
21007 ::reqwest::header::ACCEPT,
21008 ::reqwest::header::HeaderValue::from_static("application/json"),
21009 )
21010 .json(&body)
21011 .headers(header_map)
21012 .build()?;
21013 let info = OperationInfo {
21014 operation_id: "create_category",
21015 };
21016 self.pre(&mut request, &info).await?;
21017 let result = self.exec(request, &info).await;
21018 self.post(&result, &info).await?;
21019 let response = result?;
21020 match response.status().as_u16() {
21021 200u16 => ResponseValue::from_response(response).await,
21022 _ => Err(Error::UnexpectedResponse(response)),
21023 }
21024 }
21025
21026 ///List default categories by user
21027 ///
21028 ///Use this endpoint to retrieve a list of all the default categories and
21029 /// subcategories, scoped by user, offered within the MX Platform API. In
21030 /// other words, each item in the returned list will have its `is_default`
21031 /// field set to `true`. There are currently 119 default categories and
21032 /// subcategories. Both the _list default categories_ and _list default
21033 /// categories by user_ endpoints return the same results. The different
21034 /// routes are provided for convenience.
21035 ///
21036 ///Sends a `GET` request to `/users/{user_guid}/categories/default`
21037 ///
21038 ///Arguments:
21039 /// - `user_guid`: The unique identifier for a `user`, beginning with the
21040 /// prefix `USR-`.
21041 /// - `page`: Results are paginated. Specify current page.
21042 /// - `records_per_page`: This specifies the number of records to be
21043 /// returned on each page. Defaults to `25`. The valid range is from `10`
21044 /// to `1000`. If the value exceeds `1000`, the default value of `25` will
21045 /// be used instead.
21046 pub async fn list_default_categories_by_user<'a>(
21047 &'a self,
21048 user_guid: &'a str,
21049 page: Option<i64>,
21050 records_per_page: Option<i64>,
21051 ) -> Result<ResponseValue<types::CategoriesResponseBody>, Error<()>> {
21052 let url = format!(
21053 "{}/users/{}/categories/default",
21054 self.baseurl,
21055 encode_path(&user_guid.to_string()),
21056 );
21057 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
21058 header_map.append(
21059 ::reqwest::header::HeaderName::from_static("api-version"),
21060 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
21061 );
21062 #[allow(unused_mut)]
21063 let mut request = self
21064 .client
21065 .get(url)
21066 .header(
21067 ::reqwest::header::ACCEPT,
21068 ::reqwest::header::HeaderValue::from_static("application/json"),
21069 )
21070 .query(&progenitor_client::QueryParam::new("page", &page))
21071 .query(&progenitor_client::QueryParam::new(
21072 "records_per_page",
21073 &records_per_page,
21074 ))
21075 .headers(header_map)
21076 .build()?;
21077 let info = OperationInfo {
21078 operation_id: "list_default_categories_by_user",
21079 };
21080 self.pre(&mut request, &info).await?;
21081 let result = self.exec(request, &info).await;
21082 self.post(&result, &info).await?;
21083 let response = result?;
21084 match response.status().as_u16() {
21085 200u16 => ResponseValue::from_response(response).await,
21086 _ => Err(Error::UnexpectedResponse(response)),
21087 }
21088 }
21089
21090 ///Read a custom category
21091 ///
21092 ///Use this endpoint to read the attributes of either a default category or
21093 /// a custom category.
21094 ///
21095 ///Sends a `GET` request to `/users/{user_guid}/categories/{category_guid}`
21096 ///
21097 ///Arguments:
21098 /// - `user_guid`: The unique identifier for a `user`, beginning with the
21099 /// prefix `USR-`.
21100 /// - `category_guid`: The unique id for a `category`.
21101 pub async fn read_category<'a>(
21102 &'a self,
21103 user_guid: &'a str,
21104 category_guid: &'a str,
21105 ) -> Result<ResponseValue<types::CategoryResponseBody>, Error<()>> {
21106 let url = format!(
21107 "{}/users/{}/categories/{}",
21108 self.baseurl,
21109 encode_path(&user_guid.to_string()),
21110 encode_path(&category_guid.to_string()),
21111 );
21112 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
21113 header_map.append(
21114 ::reqwest::header::HeaderName::from_static("api-version"),
21115 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
21116 );
21117 #[allow(unused_mut)]
21118 let mut request = self
21119 .client
21120 .get(url)
21121 .header(
21122 ::reqwest::header::ACCEPT,
21123 ::reqwest::header::HeaderValue::from_static("application/json"),
21124 )
21125 .headers(header_map)
21126 .build()?;
21127 let info = OperationInfo {
21128 operation_id: "read_category",
21129 };
21130 self.pre(&mut request, &info).await?;
21131 let result = self.exec(request, &info).await;
21132 self.post(&result, &info).await?;
21133 let response = result?;
21134 match response.status().as_u16() {
21135 200u16 => ResponseValue::from_response(response).await,
21136 _ => Err(Error::UnexpectedResponse(response)),
21137 }
21138 }
21139
21140 ///Update category
21141 ///
21142 ///Use this endpoint to update the attributes of a custom category
21143 /// according to its unique GUID.
21144 ///
21145 ///Sends a `PUT` request to `/users/{user_guid}/categories/{category_guid}`
21146 ///
21147 ///Arguments:
21148 /// - `user_guid`: The unique identifier for a `user`, beginning with the
21149 /// prefix `USR-`.
21150 /// - `category_guid`: The unique id for a `category`.
21151 /// - `body`: Category object to be updated (While no single parameter is
21152 /// required, the `category` object cannot be empty)
21153 pub async fn update_category<'a>(
21154 &'a self,
21155 user_guid: &'a str,
21156 category_guid: &'a str,
21157 body: &'a types::CategoryUpdateRequestBody,
21158 ) -> Result<ResponseValue<types::CategoryResponseBody>, Error<()>> {
21159 let url = format!(
21160 "{}/users/{}/categories/{}",
21161 self.baseurl,
21162 encode_path(&user_guid.to_string()),
21163 encode_path(&category_guid.to_string()),
21164 );
21165 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
21166 header_map.append(
21167 ::reqwest::header::HeaderName::from_static("api-version"),
21168 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
21169 );
21170 #[allow(unused_mut)]
21171 let mut request = self
21172 .client
21173 .put(url)
21174 .header(
21175 ::reqwest::header::ACCEPT,
21176 ::reqwest::header::HeaderValue::from_static("application/json"),
21177 )
21178 .json(&body)
21179 .headers(header_map)
21180 .build()?;
21181 let info = OperationInfo {
21182 operation_id: "update_category",
21183 };
21184 self.pre(&mut request, &info).await?;
21185 let result = self.exec(request, &info).await;
21186 self.post(&result, &info).await?;
21187 let response = result?;
21188 match response.status().as_u16() {
21189 200u16 => ResponseValue::from_response(response).await,
21190 _ => Err(Error::UnexpectedResponse(response)),
21191 }
21192 }
21193
21194 ///Delete category
21195 ///
21196 ///Use this endpoint to delete a specific custom category according to its
21197 /// unique GUID. The API will respond with an empty object and a status of
21198 /// `204 No Content`.
21199 ///
21200 ///Sends a `DELETE` request to
21201 /// `/users/{user_guid}/categories/{category_guid}`
21202 ///
21203 ///Arguments:
21204 /// - `user_guid`: The unique identifier for a `user`, beginning with the
21205 /// prefix `USR-`.
21206 /// - `category_guid`: The unique id for a `category`.
21207 pub async fn delete_category<'a>(
21208 &'a self,
21209 user_guid: &'a str,
21210 category_guid: &'a str,
21211 ) -> Result<ResponseValue<()>, Error<()>> {
21212 let url = format!(
21213 "{}/users/{}/categories/{}",
21214 self.baseurl,
21215 encode_path(&user_guid.to_string()),
21216 encode_path(&category_guid.to_string()),
21217 );
21218 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
21219 header_map.append(
21220 ::reqwest::header::HeaderName::from_static("api-version"),
21221 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
21222 );
21223 #[allow(unused_mut)]
21224 let mut request = self.client.delete(url).headers(header_map).build()?;
21225 let info = OperationInfo {
21226 operation_id: "delete_category",
21227 };
21228 self.pre(&mut request, &info).await?;
21229 let result = self.exec(request, &info).await;
21230 self.post(&result, &info).await?;
21231 let response = result?;
21232 match response.status().as_u16() {
21233 204u16 => Ok(ResponseValue::empty(response)),
21234 _ => Err(Error::UnexpectedResponse(response)),
21235 }
21236 }
21237
21238 ///(Deprecated) Request connect widget URL
21239 ///
21240 ///This endpoint will return a URL for an embeddable version of MX Connect.
21241 ///
21242 ///Sends a `POST` request to `/users/{user_guid}/connect_widget_url`
21243 ///
21244 ///Arguments:
21245 /// - `user_guid`: The unique identifier for a `user`, beginning with the
21246 /// prefix `USR-`.
21247 /// - `body`: Optional config options for WebView (is_mobile_webview,
21248 /// current_institution_code, current_member_guid, update_credentials)
21249 pub async fn request_connect_widget_url<'a>(
21250 &'a self,
21251 user_guid: &'a str,
21252 body: &'a types::ConnectWidgetRequestBody,
21253 ) -> Result<ResponseValue<types::ConnectWidgetResponseBody>, Error<()>> {
21254 let url = format!(
21255 "{}/users/{}/connect_widget_url",
21256 self.baseurl,
21257 encode_path(&user_guid.to_string()),
21258 );
21259 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
21260 header_map.append(
21261 ::reqwest::header::HeaderName::from_static("api-version"),
21262 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
21263 );
21264 #[allow(unused_mut)]
21265 let mut request = self
21266 .client
21267 .post(url)
21268 .header(
21269 ::reqwest::header::ACCEPT,
21270 ::reqwest::header::HeaderValue::from_static("application/json"),
21271 )
21272 .json(&body)
21273 .headers(header_map)
21274 .build()?;
21275 let info = OperationInfo {
21276 operation_id: "request_connect_widget_url",
21277 };
21278 self.pre(&mut request, &info).await?;
21279 let result = self.exec(request, &info).await;
21280 self.post(&result, &info).await?;
21281 let response = result?;
21282 match response.status().as_u16() {
21283 200u16 => ResponseValue::from_response(response).await,
21284 _ => Err(Error::UnexpectedResponse(response)),
21285 }
21286 }
21287
21288 ///List all insights for a user
21289 ///
21290 ///Use this endpoint to list all the insights associated with the user.
21291 ///
21292 ///Sends a `GET` request to `/users/{user_guid}/insights`
21293 ///
21294 ///Arguments:
21295 /// - `user_guid`: The unique identifier for a `user`, beginning with the
21296 /// prefix `USR-`.
21297 /// - `page`: Results are paginated. Specify current page.
21298 /// - `records_per_page`: This specifies the number of records to be
21299 /// returned on each page. Defaults to `25`. The valid range is from `10`
21300 /// to `100`. If the value exceeds `100`, the default value of `25` will
21301 /// be used instead.
21302 pub async fn list_insights_user<'a>(
21303 &'a self,
21304 user_guid: &'a str,
21305 page: Option<i64>,
21306 records_per_page: Option<i64>,
21307 ) -> Result<ResponseValue<types::InsightsResponseBody>, Error<()>> {
21308 let url = format!(
21309 "{}/users/{}/insights",
21310 self.baseurl,
21311 encode_path(&user_guid.to_string()),
21312 );
21313 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
21314 header_map.append(
21315 ::reqwest::header::HeaderName::from_static("api-version"),
21316 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
21317 );
21318 #[allow(unused_mut)]
21319 let mut request = self
21320 .client
21321 .get(url)
21322 .header(
21323 ::reqwest::header::ACCEPT,
21324 ::reqwest::header::HeaderValue::from_static("application/json"),
21325 )
21326 .query(&progenitor_client::QueryParam::new("page", &page))
21327 .query(&progenitor_client::QueryParam::new(
21328 "records_per_page",
21329 &records_per_page,
21330 ))
21331 .headers(header_map)
21332 .build()?;
21333 let info = OperationInfo {
21334 operation_id: "list_insights_user",
21335 };
21336 self.pre(&mut request, &info).await?;
21337 let result = self.exec(request, &info).await;
21338 self.post(&result, &info).await?;
21339 let response = result?;
21340 match response.status().as_u16() {
21341 200u16 => ResponseValue::from_response(response).await,
21342 _ => Err(Error::UnexpectedResponse(response)),
21343 }
21344 }
21345
21346 ///List all categories associated with an insight
21347 ///
21348 ///Use this endpoint to list all the categories associated with the
21349 /// insight.
21350 ///
21351 ///Sends a `GET` request to
21352 /// `/users/{user_guid}/insights/{insight_guid}/categories`
21353 ///
21354 ///Arguments:
21355 /// - `user_guid`: The unique identifier for a `user`, beginning with the
21356 /// prefix `USR-`.
21357 /// - `insight_guid`: The unique identifier for the insight. Defined by MX.
21358 /// - `page`: Results are paginated. Specify current page.
21359 /// - `records_per_page`: This specifies the number of records to be
21360 /// returned on each page. Defaults to `25`. The valid range is from `10`
21361 /// to `100`. If the value exceeds `100`, the default value of `25` will
21362 /// be used instead.
21363 pub async fn list_categories_insight<'a>(
21364 &'a self,
21365 user_guid: &'a str,
21366 insight_guid: &'a str,
21367 page: Option<i64>,
21368 records_per_page: Option<i64>,
21369 ) -> Result<ResponseValue<types::CategoriesResponseBody>, Error<()>> {
21370 let url = format!(
21371 "{}/users/{}/insights/{}/categories",
21372 self.baseurl,
21373 encode_path(&user_guid.to_string()),
21374 encode_path(&insight_guid.to_string()),
21375 );
21376 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
21377 header_map.append(
21378 ::reqwest::header::HeaderName::from_static("api-version"),
21379 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
21380 );
21381 #[allow(unused_mut)]
21382 let mut request = self
21383 .client
21384 .get(url)
21385 .header(
21386 ::reqwest::header::ACCEPT,
21387 ::reqwest::header::HeaderValue::from_static("application/json"),
21388 )
21389 .query(&progenitor_client::QueryParam::new("page", &page))
21390 .query(&progenitor_client::QueryParam::new(
21391 "records_per_page",
21392 &records_per_page,
21393 ))
21394 .headers(header_map)
21395 .build()?;
21396 let info = OperationInfo {
21397 operation_id: "list_categories_insight",
21398 };
21399 self.pre(&mut request, &info).await?;
21400 let result = self.exec(request, &info).await;
21401 self.post(&result, &info).await?;
21402 let response = result?;
21403 match response.status().as_u16() {
21404 200u16 => ResponseValue::from_response(response).await,
21405 _ => Err(Error::UnexpectedResponse(response)),
21406 }
21407 }
21408
21409 ///List all accounts associated with an insight
21410 ///
21411 ///Use this endpoint to list all the accounts associated with the insight.
21412 ///
21413 ///Sends a `GET` request to
21414 /// `/users/{user_guid}/insights/{insight_guid}/accounts`
21415 ///
21416 ///Arguments:
21417 /// - `user_guid`: The unique identifier for a `user`, beginning with the
21418 /// prefix `USR-`.
21419 /// - `insight_guid`: The unique identifier for the insight. Defined by MX.
21420 /// - `page`: Results are paginated. Specify current page.
21421 /// - `records_per_page`: This specifies the number of records to be
21422 /// returned on each page. Defaults to `25`. The valid range is from `10`
21423 /// to `100`. If the value exceeds `100`, the default value of `25` will
21424 /// be used instead.
21425 pub async fn list_accounts_insight<'a>(
21426 &'a self,
21427 user_guid: &'a str,
21428 insight_guid: &'a str,
21429 page: Option<i64>,
21430 records_per_page: Option<i64>,
21431 ) -> Result<ResponseValue<types::AccountsResponseBody>, Error<()>> {
21432 let url = format!(
21433 "{}/users/{}/insights/{}/accounts",
21434 self.baseurl,
21435 encode_path(&user_guid.to_string()),
21436 encode_path(&insight_guid.to_string()),
21437 );
21438 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
21439 header_map.append(
21440 ::reqwest::header::HeaderName::from_static("api-version"),
21441 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
21442 );
21443 #[allow(unused_mut)]
21444 let mut request = self
21445 .client
21446 .get(url)
21447 .header(
21448 ::reqwest::header::ACCEPT,
21449 ::reqwest::header::HeaderValue::from_static("application/json"),
21450 )
21451 .query(&progenitor_client::QueryParam::new("page", &page))
21452 .query(&progenitor_client::QueryParam::new(
21453 "records_per_page",
21454 &records_per_page,
21455 ))
21456 .headers(header_map)
21457 .build()?;
21458 let info = OperationInfo {
21459 operation_id: "list_accounts_insight",
21460 };
21461 self.pre(&mut request, &info).await?;
21462 let result = self.exec(request, &info).await;
21463 self.post(&result, &info).await?;
21464 let response = result?;
21465 match response.status().as_u16() {
21466 200u16 => ResponseValue::from_response(response).await,
21467 _ => Err(Error::UnexpectedResponse(response)),
21468 }
21469 }
21470
21471 ///List all merchants associated with an insight
21472 ///
21473 ///Use this endpoint to list all the merchants associated with the insight.
21474 ///
21475 ///Sends a `GET` request to
21476 /// `/users/{user_guid}/insights/{insight_guid}/merchants`
21477 ///
21478 ///Arguments:
21479 /// - `user_guid`: The unique identifier for a `user`, beginning with the
21480 /// prefix `USR-`.
21481 /// - `insight_guid`: The unique identifier for the insight. Defined by MX.
21482 /// - `page`: Results are paginated. Specify current page.
21483 /// - `records_per_page`: This specifies the number of records to be
21484 /// returned on each page. Defaults to `25`. The valid range is from `10`
21485 /// to `100`. If the value exceeds `100`, the default value of `25` will
21486 /// be used instead.
21487 pub async fn list_merchants_insight<'a>(
21488 &'a self,
21489 user_guid: &'a str,
21490 insight_guid: &'a str,
21491 page: Option<i64>,
21492 records_per_page: Option<i64>,
21493 ) -> Result<ResponseValue<types::MerchantsResponseBody>, Error<()>> {
21494 let url = format!(
21495 "{}/users/{}/insights/{}/merchants",
21496 self.baseurl,
21497 encode_path(&user_guid.to_string()),
21498 encode_path(&insight_guid.to_string()),
21499 );
21500 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
21501 header_map.append(
21502 ::reqwest::header::HeaderName::from_static("api-version"),
21503 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
21504 );
21505 #[allow(unused_mut)]
21506 let mut request = self
21507 .client
21508 .get(url)
21509 .header(
21510 ::reqwest::header::ACCEPT,
21511 ::reqwest::header::HeaderValue::from_static("application/json"),
21512 )
21513 .query(&progenitor_client::QueryParam::new("page", &page))
21514 .query(&progenitor_client::QueryParam::new(
21515 "records_per_page",
21516 &records_per_page,
21517 ))
21518 .headers(header_map)
21519 .build()?;
21520 let info = OperationInfo {
21521 operation_id: "list_merchants_insight",
21522 };
21523 self.pre(&mut request, &info).await?;
21524 let result = self.exec(request, &info).await;
21525 self.post(&result, &info).await?;
21526 let response = result?;
21527 match response.status().as_u16() {
21528 200u16 => ResponseValue::from_response(response).await,
21529 _ => Err(Error::UnexpectedResponse(response)),
21530 }
21531 }
21532
21533 ///List all scheduled payments associated with an insight
21534 ///
21535 ///Use this endpoint to list all the scheduled payments associated with the
21536 /// insight.
21537 ///
21538 ///Sends a `GET` request to
21539 /// `/users/{user_guid}/insights/{insight_guid}/scheduled_payments`
21540 ///
21541 ///Arguments:
21542 /// - `user_guid`: The unique identifier for a `user`, beginning with the
21543 /// prefix `USR-`.
21544 /// - `insight_guid`: The unique identifier for the insight. Defined by MX.
21545 /// - `page`: Results are paginated. Specify current page.
21546 /// - `records_per_page`: This specifies the number of records to be
21547 /// returned on each page. Defaults to `25`. The valid range is from `10`
21548 /// to `100`. If the value exceeds `100`, the default value of `25` will
21549 /// be used instead.
21550 pub async fn list_scheduled_payments_insight<'a>(
21551 &'a self,
21552 user_guid: &'a str,
21553 insight_guid: &'a str,
21554 page: Option<i64>,
21555 records_per_page: Option<i64>,
21556 ) -> Result<ResponseValue<types::ScheduledPaymentsResponseBody>, Error<()>> {
21557 let url = format!(
21558 "{}/users/{}/insights/{}/scheduled_payments",
21559 self.baseurl,
21560 encode_path(&user_guid.to_string()),
21561 encode_path(&insight_guid.to_string()),
21562 );
21563 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
21564 header_map.append(
21565 ::reqwest::header::HeaderName::from_static("api-version"),
21566 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
21567 );
21568 #[allow(unused_mut)]
21569 let mut request = self
21570 .client
21571 .get(url)
21572 .header(
21573 ::reqwest::header::ACCEPT,
21574 ::reqwest::header::HeaderValue::from_static("application/json"),
21575 )
21576 .query(&progenitor_client::QueryParam::new("page", &page))
21577 .query(&progenitor_client::QueryParam::new(
21578 "records_per_page",
21579 &records_per_page,
21580 ))
21581 .headers(header_map)
21582 .build()?;
21583 let info = OperationInfo {
21584 operation_id: "list_scheduled_payments_insight",
21585 };
21586 self.pre(&mut request, &info).await?;
21587 let result = self.exec(request, &info).await;
21588 self.post(&result, &info).await?;
21589 let response = result?;
21590 match response.status().as_u16() {
21591 200u16 => ResponseValue::from_response(response).await,
21592 _ => Err(Error::UnexpectedResponse(response)),
21593 }
21594 }
21595
21596 ///List all transactions associated with an insight
21597 ///
21598 ///Use this endpoint to list all the transactions associated with the
21599 /// insight.
21600 ///
21601 ///Sends a `GET` request to
21602 /// `/users/{user_guid}/insights/{insight_guid}/transactions`
21603 ///
21604 ///Arguments:
21605 /// - `user_guid`: The unique identifier for a `user`, beginning with the
21606 /// prefix `USR-`.
21607 /// - `insight_guid`: The unique identifier for the insight. Defined by MX.
21608 /// - `page`: Results are paginated. Specify current page.
21609 /// - `records_per_page`: This specifies the number of records to be
21610 /// returned on each page. Defaults to `25`. The valid range is from `10`
21611 /// to `100`. If the value exceeds `100`, the default value of `25` will
21612 /// be used instead.
21613 pub async fn list_transactions_insight<'a>(
21614 &'a self,
21615 user_guid: &'a str,
21616 insight_guid: &'a str,
21617 page: Option<i64>,
21618 records_per_page: Option<i64>,
21619 ) -> Result<ResponseValue<types::TransactionsResponseBody>, Error<()>> {
21620 let url = format!(
21621 "{}/users/{}/insights/{}/transactions",
21622 self.baseurl,
21623 encode_path(&user_guid.to_string()),
21624 encode_path(&insight_guid.to_string()),
21625 );
21626 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
21627 header_map.append(
21628 ::reqwest::header::HeaderName::from_static("api-version"),
21629 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
21630 );
21631 #[allow(unused_mut)]
21632 let mut request = self
21633 .client
21634 .get(url)
21635 .header(
21636 ::reqwest::header::ACCEPT,
21637 ::reqwest::header::HeaderValue::from_static("application/json"),
21638 )
21639 .query(&progenitor_client::QueryParam::new("page", &page))
21640 .query(&progenitor_client::QueryParam::new(
21641 "records_per_page",
21642 &records_per_page,
21643 ))
21644 .headers(header_map)
21645 .build()?;
21646 let info = OperationInfo {
21647 operation_id: "list_transactions_insight",
21648 };
21649 self.pre(&mut request, &info).await?;
21650 let result = self.exec(request, &info).await;
21651 self.post(&result, &info).await?;
21652 let response = result?;
21653 match response.status().as_u16() {
21654 200u16 => ResponseValue::from_response(response).await,
21655 _ => Err(Error::UnexpectedResponse(response)),
21656 }
21657 }
21658
21659 ///Read insight
21660 ///
21661 ///Use this endpoint to read the attributes of an insight according to its
21662 /// unique GUID.
21663 ///
21664 ///Sends a `GET` request to `/users/{user_guid}/insights/{insight_guid}`
21665 ///
21666 ///Arguments:
21667 /// - `user_guid`: The unique identifier for a `user`, beginning with the
21668 /// prefix `USR-`.
21669 /// - `insight_guid`: The unique identifier for the insight. Defined by MX.
21670 pub async fn read_insight_user<'a>(
21671 &'a self,
21672 user_guid: &'a str,
21673 insight_guid: &'a str,
21674 ) -> Result<ResponseValue<types::InsightResponseBody>, Error<()>> {
21675 let url = format!(
21676 "{}/users/{}/insights/{}",
21677 self.baseurl,
21678 encode_path(&user_guid.to_string()),
21679 encode_path(&insight_guid.to_string()),
21680 );
21681 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
21682 header_map.append(
21683 ::reqwest::header::HeaderName::from_static("api-version"),
21684 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
21685 );
21686 #[allow(unused_mut)]
21687 let mut request = self
21688 .client
21689 .get(url)
21690 .header(
21691 ::reqwest::header::ACCEPT,
21692 ::reqwest::header::HeaderValue::from_static("application/json"),
21693 )
21694 .headers(header_map)
21695 .build()?;
21696 let info = OperationInfo {
21697 operation_id: "read_insight_user",
21698 };
21699 self.pre(&mut request, &info).await?;
21700 let result = self.exec(request, &info).await;
21701 self.post(&result, &info).await?;
21702 let response = result?;
21703 match response.status().as_u16() {
21704 200u16 => ResponseValue::from_response(response).await,
21705 _ => Err(Error::UnexpectedResponse(response)),
21706 }
21707 }
21708
21709 ///Update insight
21710 ///
21711 ///Use this endpoint to update the attributes of an insight according to
21712 /// its unique GUID.
21713 ///
21714 ///Sends a `PUT` request to `/users/{user_guid}/insights/{insight_guid}`
21715 ///
21716 ///Arguments:
21717 /// - `user_guid`: The unique identifier for a `user`, beginning with the
21718 /// prefix `USR-`.
21719 /// - `insight_guid`: The unique identifier for the insight. Defined by MX.
21720 /// - `body`: The insight to be updated (None of these parameters are
21721 /// required, but the user object cannot be empty.)
21722 pub async fn update_insight<'a>(
21723 &'a self,
21724 user_guid: &'a str,
21725 insight_guid: &'a str,
21726 body: &'a types::InsightUpdateRequestBody,
21727 ) -> Result<ResponseValue<types::InsightResponse>, Error<()>> {
21728 let url = format!(
21729 "{}/users/{}/insights/{}",
21730 self.baseurl,
21731 encode_path(&user_guid.to_string()),
21732 encode_path(&insight_guid.to_string()),
21733 );
21734 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
21735 header_map.append(
21736 ::reqwest::header::HeaderName::from_static("api-version"),
21737 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
21738 );
21739 #[allow(unused_mut)]
21740 let mut request = self
21741 .client
21742 .put(url)
21743 .header(
21744 ::reqwest::header::ACCEPT,
21745 ::reqwest::header::HeaderValue::from_static("application/json"),
21746 )
21747 .json(&body)
21748 .headers(header_map)
21749 .build()?;
21750 let info = OperationInfo {
21751 operation_id: "update_insight",
21752 };
21753 self.pre(&mut request, &info).await?;
21754 let result = self.exec(request, &info).await;
21755 self.post(&result, &info).await?;
21756 let response = result?;
21757 match response.status().as_u16() {
21758 200u16 => ResponseValue::from_response(response).await,
21759 _ => Err(Error::UnexpectedResponse(response)),
21760 }
21761 }
21762
21763 ///List managed members
21764 ///
21765 ///This endpoint returns a list of all the partner-managed members
21766 /// associated with the specified `user`.
21767 ///
21768 ///Sends a `GET` request to `/users/{user_guid}/managed_members`
21769 ///
21770 ///Arguments:
21771 /// - `user_guid`: The unique identifier for a `user`, beginning with the
21772 /// prefix `USR-`.
21773 /// - `page`: Results are paginated. Specify current page.
21774 /// - `records_per_page`: This specifies the number of records to be
21775 /// returned on each page. Defaults to `25`. The valid range is from `10`
21776 /// to `1000`. If the value exceeds `1000`, the default value of `25` will
21777 /// be used instead.
21778 pub async fn list_managed_members<'a>(
21779 &'a self,
21780 user_guid: &'a str,
21781 page: Option<i64>,
21782 records_per_page: Option<i64>,
21783 ) -> Result<ResponseValue<types::MembersResponseBody>, Error<()>> {
21784 let url = format!(
21785 "{}/users/{}/managed_members",
21786 self.baseurl,
21787 encode_path(&user_guid.to_string()),
21788 );
21789 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
21790 header_map.append(
21791 ::reqwest::header::HeaderName::from_static("api-version"),
21792 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
21793 );
21794 #[allow(unused_mut)]
21795 let mut request = self
21796 .client
21797 .get(url)
21798 .header(
21799 ::reqwest::header::ACCEPT,
21800 ::reqwest::header::HeaderValue::from_static("application/json"),
21801 )
21802 .query(&progenitor_client::QueryParam::new("page", &page))
21803 .query(&progenitor_client::QueryParam::new(
21804 "records_per_page",
21805 &records_per_page,
21806 ))
21807 .headers(header_map)
21808 .build()?;
21809 let info = OperationInfo {
21810 operation_id: "list_managed_members",
21811 };
21812 self.pre(&mut request, &info).await?;
21813 let result = self.exec(request, &info).await;
21814 self.post(&result, &info).await?;
21815 let response = result?;
21816 match response.status().as_u16() {
21817 200u16 => ResponseValue::from_response(response).await,
21818 _ => Err(Error::UnexpectedResponse(response)),
21819 }
21820 }
21821
21822 ///Create managed member
21823 ///
21824 ///Use this endpoint to create a new partner-managed `member`.
21825 ///
21826 ///Sends a `POST` request to `/users/{user_guid}/managed_members`
21827 ///
21828 ///Arguments:
21829 /// - `user_guid`: The unique identifier for a `user`, beginning with the
21830 /// prefix `USR-`.
21831 /// - `body`: Managed member to be created.
21832 pub async fn create_managed_member<'a>(
21833 &'a self,
21834 user_guid: &'a str,
21835 body: &'a types::ManagedMemberCreateRequestBody,
21836 ) -> Result<ResponseValue<types::MemberResponseBody>, Error<()>> {
21837 let url = format!(
21838 "{}/users/{}/managed_members",
21839 self.baseurl,
21840 encode_path(&user_guid.to_string()),
21841 );
21842 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
21843 header_map.append(
21844 ::reqwest::header::HeaderName::from_static("api-version"),
21845 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
21846 );
21847 #[allow(unused_mut)]
21848 let mut request = self
21849 .client
21850 .post(url)
21851 .header(
21852 ::reqwest::header::ACCEPT,
21853 ::reqwest::header::HeaderValue::from_static("application/json"),
21854 )
21855 .json(&body)
21856 .headers(header_map)
21857 .build()?;
21858 let info = OperationInfo {
21859 operation_id: "create_managed_member",
21860 };
21861 self.pre(&mut request, &info).await?;
21862 let result = self.exec(request, &info).await;
21863 self.post(&result, &info).await?;
21864 let response = result?;
21865 match response.status().as_u16() {
21866 202u16 => ResponseValue::from_response(response).await,
21867 _ => Err(Error::UnexpectedResponse(response)),
21868 }
21869 }
21870
21871 ///Read managed member
21872 ///
21873 ///This endpoint returns the attributes of the specified
21874 /// partner-managed`member`.
21875 ///
21876 ///Sends a `GET` request to
21877 /// `/users/{user_guid}/managed_members/{member_guid}`
21878 ///
21879 ///Arguments:
21880 /// - `user_guid`: The unique identifier for a `user`, beginning with the
21881 /// prefix `USR-`.
21882 /// - `member_guid`: The unique id for a `member`.
21883 pub async fn read_managed_member<'a>(
21884 &'a self,
21885 user_guid: &'a str,
21886 member_guid: &'a str,
21887 ) -> Result<ResponseValue<types::MemberResponseBody>, Error<()>> {
21888 let url = format!(
21889 "{}/users/{}/managed_members/{}",
21890 self.baseurl,
21891 encode_path(&user_guid.to_string()),
21892 encode_path(&member_guid.to_string()),
21893 );
21894 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
21895 header_map.append(
21896 ::reqwest::header::HeaderName::from_static("api-version"),
21897 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
21898 );
21899 #[allow(unused_mut)]
21900 let mut request = self
21901 .client
21902 .get(url)
21903 .header(
21904 ::reqwest::header::ACCEPT,
21905 ::reqwest::header::HeaderValue::from_static("application/json"),
21906 )
21907 .headers(header_map)
21908 .build()?;
21909 let info = OperationInfo {
21910 operation_id: "read_managed_member",
21911 };
21912 self.pre(&mut request, &info).await?;
21913 let result = self.exec(request, &info).await;
21914 self.post(&result, &info).await?;
21915 let response = result?;
21916 match response.status().as_u16() {
21917 200u16 => ResponseValue::from_response(response).await,
21918 _ => Err(Error::UnexpectedResponse(response)),
21919 }
21920 }
21921
21922 ///Update managed member
21923 ///
21924 ///Use this endpoint to update the attributes of the specified
21925 /// partner_managed `member`.
21926 ///
21927 ///Sends a `PUT` request to
21928 /// `/users/{user_guid}/managed_members/{member_guid}`
21929 ///
21930 ///Arguments:
21931 /// - `user_guid`: The unique identifier for a `user`, beginning with the
21932 /// prefix `USR-`.
21933 /// - `member_guid`: The unique id for a `member`.
21934 /// - `body`: Managed member object to be updated (While no single parameter
21935 /// is required, the request body can't be empty)
21936 pub async fn update_managed_member<'a>(
21937 &'a self,
21938 user_guid: &'a str,
21939 member_guid: &'a str,
21940 body: &'a types::ManagedMemberUpdateRequestBody,
21941 ) -> Result<ResponseValue<types::MemberResponseBody>, Error<()>> {
21942 let url = format!(
21943 "{}/users/{}/managed_members/{}",
21944 self.baseurl,
21945 encode_path(&user_guid.to_string()),
21946 encode_path(&member_guid.to_string()),
21947 );
21948 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
21949 header_map.append(
21950 ::reqwest::header::HeaderName::from_static("api-version"),
21951 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
21952 );
21953 #[allow(unused_mut)]
21954 let mut request = self
21955 .client
21956 .put(url)
21957 .header(
21958 ::reqwest::header::ACCEPT,
21959 ::reqwest::header::HeaderValue::from_static("application/json"),
21960 )
21961 .json(&body)
21962 .headers(header_map)
21963 .build()?;
21964 let info = OperationInfo {
21965 operation_id: "update_managed_member",
21966 };
21967 self.pre(&mut request, &info).await?;
21968 let result = self.exec(request, &info).await;
21969 self.post(&result, &info).await?;
21970 let response = result?;
21971 match response.status().as_u16() {
21972 200u16 => ResponseValue::from_response(response).await,
21973 _ => Err(Error::UnexpectedResponse(response)),
21974 }
21975 }
21976
21977 ///Delete managed member
21978 ///
21979 ///Use this endpoint to delete the specified partner-managed `member`. The
21980 /// endpoint will respond with a status of `204 No Content` without a
21981 /// resource.
21982 ///
21983 ///Sends a `DELETE` request to
21984 /// `/users/{user_guid}/managed_members/{member_guid}`
21985 ///
21986 ///Arguments:
21987 /// - `user_guid`: The unique identifier for a `user`, beginning with the
21988 /// prefix `USR-`.
21989 /// - `member_guid`: The unique id for a `member`.
21990 /// - `accept`: Specifies the media type expected in the response.
21991 pub async fn delete_managed_member<'a>(
21992 &'a self,
21993 user_guid: &'a str,
21994 member_guid: &'a str,
21995 accept: &'a str,
21996 ) -> Result<ResponseValue<()>, Error<()>> {
21997 let url = format!(
21998 "{}/users/{}/managed_members/{}",
21999 self.baseurl,
22000 encode_path(&user_guid.to_string()),
22001 encode_path(&member_guid.to_string()),
22002 );
22003 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(2usize);
22004 header_map.append(
22005 ::reqwest::header::HeaderName::from_static("api-version"),
22006 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
22007 );
22008 header_map.append("Accept", accept.to_string().try_into()?);
22009 #[allow(unused_mut)]
22010 let mut request = self.client.delete(url).headers(header_map).build()?;
22011 let info = OperationInfo {
22012 operation_id: "delete_managed_member",
22013 };
22014 self.pre(&mut request, &info).await?;
22015 let result = self.exec(request, &info).await;
22016 self.post(&result, &info).await?;
22017 let response = result?;
22018 match response.status().as_u16() {
22019 204u16 => Ok(ResponseValue::empty(response)),
22020 _ => Err(Error::UnexpectedResponse(response)),
22021 }
22022 }
22023
22024 ///List managed accounts
22025 ///
22026 ///Use this endpoint to retrieve a list of all the partner-managed accounts
22027 /// associated with the given partner-managed member.
22028 ///
22029 ///Sends a `GET` request to
22030 /// `/users/{user_guid}/managed_members/{member_guid}/accounts`
22031 ///
22032 ///Arguments:
22033 /// - `user_guid`: The unique identifier for a `user`, beginning with the
22034 /// prefix `USR-`.
22035 /// - `member_guid`: The unique id for a `member`.
22036 /// - `page`: Results are paginated. Specify current page.
22037 /// - `records_per_page`: This specifies the number of records to be
22038 /// returned on each page. Defaults to `25`. The valid range is from `10`
22039 /// to `1000`. If the value exceeds `1000`, the default value of `25` will
22040 /// be used instead.
22041 pub async fn list_managed_accounts<'a>(
22042 &'a self,
22043 user_guid: &'a str,
22044 member_guid: &'a str,
22045 page: Option<i64>,
22046 records_per_page: Option<i64>,
22047 ) -> Result<ResponseValue<types::AccountsResponseBody>, Error<()>> {
22048 let url = format!(
22049 "{}/users/{}/managed_members/{}/accounts",
22050 self.baseurl,
22051 encode_path(&user_guid.to_string()),
22052 encode_path(&member_guid.to_string()),
22053 );
22054 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
22055 header_map.append(
22056 ::reqwest::header::HeaderName::from_static("api-version"),
22057 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
22058 );
22059 #[allow(unused_mut)]
22060 let mut request = self
22061 .client
22062 .get(url)
22063 .header(
22064 ::reqwest::header::ACCEPT,
22065 ::reqwest::header::HeaderValue::from_static("application/json"),
22066 )
22067 .query(&progenitor_client::QueryParam::new("page", &page))
22068 .query(&progenitor_client::QueryParam::new(
22069 "records_per_page",
22070 &records_per_page,
22071 ))
22072 .headers(header_map)
22073 .build()?;
22074 let info = OperationInfo {
22075 operation_id: "list_managed_accounts",
22076 };
22077 self.pre(&mut request, &info).await?;
22078 let result = self.exec(request, &info).await;
22079 self.post(&result, &info).await?;
22080 let response = result?;
22081 match response.status().as_u16() {
22082 200u16 => ResponseValue::from_response(response).await,
22083 _ => Err(Error::UnexpectedResponse(response)),
22084 }
22085 }
22086
22087 ///Create managed account
22088 ///
22089 ///Use this endpoint to create a partner-managed account.
22090 ///
22091 ///Sends a `POST` request to
22092 /// `/users/{user_guid}/managed_members/{member_guid}/accounts`
22093 ///
22094 ///Arguments:
22095 /// - `user_guid`: The unique identifier for a `user`, beginning with the
22096 /// prefix `USR-`.
22097 /// - `member_guid`: The unique id for a `member`.
22098 /// - `body`: Managed account to be created.
22099 pub async fn create_managed_account<'a>(
22100 &'a self,
22101 user_guid: &'a str,
22102 member_guid: &'a str,
22103 body: &'a types::ManagedAccountCreateRequestBody,
22104 ) -> Result<ResponseValue<types::AccountResponseBody>, Error<()>> {
22105 let url = format!(
22106 "{}/users/{}/managed_members/{}/accounts",
22107 self.baseurl,
22108 encode_path(&user_guid.to_string()),
22109 encode_path(&member_guid.to_string()),
22110 );
22111 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
22112 header_map.append(
22113 ::reqwest::header::HeaderName::from_static("api-version"),
22114 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
22115 );
22116 #[allow(unused_mut)]
22117 let mut request = self
22118 .client
22119 .post(url)
22120 .header(
22121 ::reqwest::header::ACCEPT,
22122 ::reqwest::header::HeaderValue::from_static("application/json"),
22123 )
22124 .json(&body)
22125 .headers(header_map)
22126 .build()?;
22127 let info = OperationInfo {
22128 operation_id: "create_managed_account",
22129 };
22130 self.pre(&mut request, &info).await?;
22131 let result = self.exec(request, &info).await;
22132 self.post(&result, &info).await?;
22133 let response = result?;
22134 match response.status().as_u16() {
22135 200u16 => ResponseValue::from_response(response).await,
22136 _ => Err(Error::UnexpectedResponse(response)),
22137 }
22138 }
22139
22140 ///Read managed account
22141 ///
22142 ///Use this endpoint to read the attributes of a partner-managed account
22143 /// according to its unique guid.
22144 ///
22145 ///Sends a `GET` request to
22146 /// `/users/{user_guid}/managed_members/{member_guid}/accounts/
22147 /// {account_guid}`
22148 ///
22149 ///Arguments:
22150 /// - `user_guid`: The unique identifier for a `user`, beginning with the
22151 /// prefix `USR-`.
22152 /// - `member_guid`: The unique id for a `member`.
22153 /// - `account_guid`: The unique id for an `account`.
22154 pub async fn read_managed_account<'a>(
22155 &'a self,
22156 user_guid: &'a str,
22157 member_guid: &'a str,
22158 account_guid: &'a str,
22159 ) -> Result<ResponseValue<types::AccountResponseBody>, Error<()>> {
22160 let url = format!(
22161 "{}/users/{}/managed_members/{}/accounts/{}",
22162 self.baseurl,
22163 encode_path(&user_guid.to_string()),
22164 encode_path(&member_guid.to_string()),
22165 encode_path(&account_guid.to_string()),
22166 );
22167 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
22168 header_map.append(
22169 ::reqwest::header::HeaderName::from_static("api-version"),
22170 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
22171 );
22172 #[allow(unused_mut)]
22173 let mut request = self
22174 .client
22175 .get(url)
22176 .header(
22177 ::reqwest::header::ACCEPT,
22178 ::reqwest::header::HeaderValue::from_static("application/json"),
22179 )
22180 .headers(header_map)
22181 .build()?;
22182 let info = OperationInfo {
22183 operation_id: "read_managed_account",
22184 };
22185 self.pre(&mut request, &info).await?;
22186 let result = self.exec(request, &info).await;
22187 self.post(&result, &info).await?;
22188 let response = result?;
22189 match response.status().as_u16() {
22190 200u16 => ResponseValue::from_response(response).await,
22191 _ => Err(Error::UnexpectedResponse(response)),
22192 }
22193 }
22194
22195 ///Update managed account
22196 ///
22197 ///Use this endpoint to update the attributes of a partner-managed account
22198 /// according to its unique GUID.
22199 ///
22200 ///Sends a `PUT` request to
22201 /// `/users/{user_guid}/managed_members/{member_guid}/accounts/
22202 /// {account_guid}`
22203 ///
22204 ///Arguments:
22205 /// - `user_guid`: The unique identifier for a `user`, beginning with the
22206 /// prefix `USR-`.
22207 /// - `member_guid`: The unique id for a `member`.
22208 /// - `account_guid`: The unique id for an `account`.
22209 /// - `body`: Managed account object to be updated (While no single
22210 /// parameter is required, the request body can't be empty)
22211 pub async fn update_managed_account<'a>(
22212 &'a self,
22213 user_guid: &'a str,
22214 member_guid: &'a str,
22215 account_guid: &'a str,
22216 body: &'a types::ManagedAccountUpdateRequestBody,
22217 ) -> Result<ResponseValue<types::AccountResponseBody>, Error<()>> {
22218 let url = format!(
22219 "{}/users/{}/managed_members/{}/accounts/{}",
22220 self.baseurl,
22221 encode_path(&user_guid.to_string()),
22222 encode_path(&member_guid.to_string()),
22223 encode_path(&account_guid.to_string()),
22224 );
22225 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
22226 header_map.append(
22227 ::reqwest::header::HeaderName::from_static("api-version"),
22228 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
22229 );
22230 #[allow(unused_mut)]
22231 let mut request = self
22232 .client
22233 .put(url)
22234 .header(
22235 ::reqwest::header::ACCEPT,
22236 ::reqwest::header::HeaderValue::from_static("application/json"),
22237 )
22238 .json(&body)
22239 .headers(header_map)
22240 .build()?;
22241 let info = OperationInfo {
22242 operation_id: "update_managed_account",
22243 };
22244 self.pre(&mut request, &info).await?;
22245 let result = self.exec(request, &info).await;
22246 self.post(&result, &info).await?;
22247 let response = result?;
22248 match response.status().as_u16() {
22249 200u16 => ResponseValue::from_response(response).await,
22250 _ => Err(Error::UnexpectedResponse(response)),
22251 }
22252 }
22253
22254 ///Delete managed account
22255 ///
22256 ///Use this endpoint to delete a partner-managed account according to its
22257 /// unique GUID. If successful, the API will respond with a status of `204
22258 /// No Content`.
22259 ///
22260 ///Sends a `DELETE` request to
22261 /// `/users/{user_guid}/managed_members/{member_guid}/accounts/
22262 /// {account_guid}`
22263 ///
22264 ///Arguments:
22265 /// - `user_guid`: The unique identifier for a `user`, beginning with the
22266 /// prefix `USR-`.
22267 /// - `member_guid`: The unique id for a `member`.
22268 /// - `account_guid`: The unique id for an `account`.
22269 pub async fn delete_managed_account<'a>(
22270 &'a self,
22271 user_guid: &'a str,
22272 member_guid: &'a str,
22273 account_guid: &'a str,
22274 ) -> Result<ResponseValue<()>, Error<()>> {
22275 let url = format!(
22276 "{}/users/{}/managed_members/{}/accounts/{}",
22277 self.baseurl,
22278 encode_path(&user_guid.to_string()),
22279 encode_path(&member_guid.to_string()),
22280 encode_path(&account_guid.to_string()),
22281 );
22282 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
22283 header_map.append(
22284 ::reqwest::header::HeaderName::from_static("api-version"),
22285 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
22286 );
22287 #[allow(unused_mut)]
22288 let mut request = self.client.delete(url).headers(header_map).build()?;
22289 let info = OperationInfo {
22290 operation_id: "delete_managed_account",
22291 };
22292 self.pre(&mut request, &info).await?;
22293 let result = self.exec(request, &info).await;
22294 self.post(&result, &info).await?;
22295 let response = result?;
22296 match response.status().as_u16() {
22297 204u16 => Ok(ResponseValue::empty(response)),
22298 _ => Err(Error::UnexpectedResponse(response)),
22299 }
22300 }
22301
22302 ///List managed transactions
22303 ///
22304 ///This endpoint returns a list of all the partner-managed transactions
22305 /// associated with the specified `account`, scoped through a `user` and a
22306 /// `member`.
22307 ///
22308 ///Sends a `GET` request to
22309 /// `/users/{user_guid}/managed_members/{member_guid}/accounts/
22310 /// {account_guid}/transactions`
22311 ///
22312 ///Arguments:
22313 /// - `user_guid`: The unique identifier for a `user`, beginning with the
22314 /// prefix `USR-`.
22315 /// - `member_guid`: The unique id for a `member`.
22316 /// - `account_guid`: The unique id for an `account`.
22317 /// - `from_date`: Filter transactions from this date. This only supports
22318 /// ISO 8601 format without timestamp (YYYY-MM-DD). Defaults to 120 days
22319 /// ago if not provided.
22320 /// - `page`: Results are paginated. Specify current page.
22321 /// - `records_per_page`: This specifies the number of records to be
22322 /// returned on each page. Defaults to `25`. The valid range is from `10`
22323 /// to `1000`. If the value exceeds `1000`, the default value of `25` will
22324 /// be used instead.
22325 /// - `to_date`: Filter transactions to this date (at midnight). This only
22326 /// supports ISO 8601 format without timestamp (YYYY-MM-DD). Defaults to 5
22327 /// days forward from the day the request is made to capture pending
22328 /// transactions.
22329 pub async fn list_managed_transactions<'a>(
22330 &'a self,
22331 user_guid: &'a str,
22332 member_guid: &'a str,
22333 account_guid: &'a str,
22334 from_date: Option<&'a str>,
22335 page: Option<i64>,
22336 records_per_page: Option<i64>,
22337 to_date: Option<&'a str>,
22338 ) -> Result<ResponseValue<types::TransactionsResponseBody>, Error<()>> {
22339 let url = format!(
22340 "{}/users/{}/managed_members/{}/accounts/{}/transactions",
22341 self.baseurl,
22342 encode_path(&user_guid.to_string()),
22343 encode_path(&member_guid.to_string()),
22344 encode_path(&account_guid.to_string()),
22345 );
22346 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
22347 header_map.append(
22348 ::reqwest::header::HeaderName::from_static("api-version"),
22349 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
22350 );
22351 #[allow(unused_mut)]
22352 let mut request = self
22353 .client
22354 .get(url)
22355 .header(
22356 ::reqwest::header::ACCEPT,
22357 ::reqwest::header::HeaderValue::from_static("application/json"),
22358 )
22359 .query(&progenitor_client::QueryParam::new("from_date", &from_date))
22360 .query(&progenitor_client::QueryParam::new("page", &page))
22361 .query(&progenitor_client::QueryParam::new(
22362 "records_per_page",
22363 &records_per_page,
22364 ))
22365 .query(&progenitor_client::QueryParam::new("to_date", &to_date))
22366 .headers(header_map)
22367 .build()?;
22368 let info = OperationInfo {
22369 operation_id: "list_managed_transactions",
22370 };
22371 self.pre(&mut request, &info).await?;
22372 let result = self.exec(request, &info).await;
22373 self.post(&result, &info).await?;
22374 let response = result?;
22375 match response.status().as_u16() {
22376 200u16 => ResponseValue::from_response(response).await,
22377 _ => Err(Error::UnexpectedResponse(response)),
22378 }
22379 }
22380
22381 ///Create managed transaction
22382 ///
22383 ///Use this endpoint to create a new partner-managed `transaction`.
22384 ///
22385 ///Sends a `POST` request to
22386 /// `/users/{user_guid}/managed_members/{member_guid}/accounts/
22387 /// {account_guid}/transactions`
22388 ///
22389 ///Arguments:
22390 /// - `user_guid`: The unique identifier for a `user`, beginning with the
22391 /// prefix `USR-`.
22392 /// - `member_guid`: The unique id for a `member`.
22393 /// - `account_guid`: The unique id for an `account`.
22394 /// - `body`: Managed transaction to be created.
22395 pub async fn create_managed_transaction<'a>(
22396 &'a self,
22397 user_guid: &'a str,
22398 member_guid: &'a str,
22399 account_guid: &'a str,
22400 body: &'a types::ManagedTransactionCreateRequestBody,
22401 ) -> Result<ResponseValue<types::TransactionResponseBody>, Error<()>> {
22402 let url = format!(
22403 "{}/users/{}/managed_members/{}/accounts/{}/transactions",
22404 self.baseurl,
22405 encode_path(&user_guid.to_string()),
22406 encode_path(&member_guid.to_string()),
22407 encode_path(&account_guid.to_string()),
22408 );
22409 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
22410 header_map.append(
22411 ::reqwest::header::HeaderName::from_static("api-version"),
22412 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
22413 );
22414 #[allow(unused_mut)]
22415 let mut request = self
22416 .client
22417 .post(url)
22418 .header(
22419 ::reqwest::header::ACCEPT,
22420 ::reqwest::header::HeaderValue::from_static("application/json"),
22421 )
22422 .json(&body)
22423 .headers(header_map)
22424 .build()?;
22425 let info = OperationInfo {
22426 operation_id: "create_managed_transaction",
22427 };
22428 self.pre(&mut request, &info).await?;
22429 let result = self.exec(request, &info).await;
22430 self.post(&result, &info).await?;
22431 let response = result?;
22432 match response.status().as_u16() {
22433 200u16 => ResponseValue::from_response(response).await,
22434 _ => Err(Error::UnexpectedResponse(response)),
22435 }
22436 }
22437
22438 ///Read managed transaction
22439 ///
22440 ///Requests to this endpoint will return the attributes of the specified
22441 /// partner-managed `transaction`.
22442 ///
22443 ///Sends a `GET` request to
22444 /// `/users/{user_guid}/managed_members/{member_guid}/accounts/
22445 /// {account_guid}/transactions/{transaction_guid}`
22446 ///
22447 ///Arguments:
22448 /// - `user_guid`: The unique identifier for a `user`, beginning with the
22449 /// prefix `USR-`.
22450 /// - `member_guid`: The unique id for a `member`.
22451 /// - `account_guid`: The unique id for an `account`.
22452 /// - `transaction_guid`: The unique id for a `transaction`.
22453 pub async fn read_managed_transaction<'a>(
22454 &'a self,
22455 user_guid: &'a str,
22456 member_guid: &'a str,
22457 account_guid: &'a str,
22458 transaction_guid: &'a str,
22459 ) -> Result<ResponseValue<types::TransactionResponseBody>, Error<()>> {
22460 let url = format!(
22461 "{}/users/{}/managed_members/{}/accounts/{}/transactions/{}",
22462 self.baseurl,
22463 encode_path(&user_guid.to_string()),
22464 encode_path(&member_guid.to_string()),
22465 encode_path(&account_guid.to_string()),
22466 encode_path(&transaction_guid.to_string()),
22467 );
22468 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
22469 header_map.append(
22470 ::reqwest::header::HeaderName::from_static("api-version"),
22471 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
22472 );
22473 #[allow(unused_mut)]
22474 let mut request = self
22475 .client
22476 .get(url)
22477 .header(
22478 ::reqwest::header::ACCEPT,
22479 ::reqwest::header::HeaderValue::from_static("application/json"),
22480 )
22481 .headers(header_map)
22482 .build()?;
22483 let info = OperationInfo {
22484 operation_id: "read_managed_transaction",
22485 };
22486 self.pre(&mut request, &info).await?;
22487 let result = self.exec(request, &info).await;
22488 self.post(&result, &info).await?;
22489 let response = result?;
22490 match response.status().as_u16() {
22491 200u16 => ResponseValue::from_response(response).await,
22492 _ => Err(Error::UnexpectedResponse(response)),
22493 }
22494 }
22495
22496 ///Update managed transaction
22497 ///
22498 ///Use this endpoint to update the attributes of the specified
22499 /// partner_managed `transaction`.
22500 ///
22501 ///Sends a `PUT` request to
22502 /// `/users/{user_guid}/managed_members/{member_guid}/accounts/
22503 /// {account_guid}/transactions/{transaction_guid}`
22504 ///
22505 ///Arguments:
22506 /// - `user_guid`: The unique identifier for a `user`, beginning with the
22507 /// prefix `USR-`.
22508 /// - `member_guid`: The unique id for a `member`.
22509 /// - `account_guid`: The unique id for an `account`.
22510 /// - `transaction_guid`: The unique id for a `transaction`.
22511 /// - `body`: Managed transaction object to be updated (While no single
22512 /// parameter is required, the request body can't be empty)
22513 pub async fn update_managed_transaction<'a>(
22514 &'a self,
22515 user_guid: &'a str,
22516 member_guid: &'a str,
22517 account_guid: &'a str,
22518 transaction_guid: &'a str,
22519 body: &'a types::ManagedTransactionUpdateRequestBody,
22520 ) -> Result<ResponseValue<types::TransactionResponseBody>, Error<()>> {
22521 let url = format!(
22522 "{}/users/{}/managed_members/{}/accounts/{}/transactions/{}",
22523 self.baseurl,
22524 encode_path(&user_guid.to_string()),
22525 encode_path(&member_guid.to_string()),
22526 encode_path(&account_guid.to_string()),
22527 encode_path(&transaction_guid.to_string()),
22528 );
22529 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
22530 header_map.append(
22531 ::reqwest::header::HeaderName::from_static("api-version"),
22532 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
22533 );
22534 #[allow(unused_mut)]
22535 let mut request = self
22536 .client
22537 .put(url)
22538 .header(
22539 ::reqwest::header::ACCEPT,
22540 ::reqwest::header::HeaderValue::from_static("application/json"),
22541 )
22542 .json(&body)
22543 .headers(header_map)
22544 .build()?;
22545 let info = OperationInfo {
22546 operation_id: "update_managed_transaction",
22547 };
22548 self.pre(&mut request, &info).await?;
22549 let result = self.exec(request, &info).await;
22550 self.post(&result, &info).await?;
22551 let response = result?;
22552 match response.status().as_u16() {
22553 200u16 => ResponseValue::from_response(response).await,
22554 _ => Err(Error::UnexpectedResponse(response)),
22555 }
22556 }
22557
22558 ///Delete managed transaction
22559 ///
22560 ///Use this endpoint to delete the specified partner-managed `transaction`.
22561 /// The endpoint will respond with a status of `204 No Content` without a
22562 /// resource.
22563 ///
22564 ///Sends a `DELETE` request to
22565 /// `/users/{user_guid}/managed_members/{member_guid}/accounts/
22566 /// {account_guid}/transactions/{transaction_guid}`
22567 ///
22568 ///Arguments:
22569 /// - `user_guid`: The unique identifier for a `user`, beginning with the
22570 /// prefix `USR-`.
22571 /// - `member_guid`: The unique id for a `member`.
22572 /// - `account_guid`: The unique id for an `account`.
22573 /// - `transaction_guid`: The unique id for a `transaction`.
22574 pub async fn delete_managed_transaction<'a>(
22575 &'a self,
22576 user_guid: &'a str,
22577 member_guid: &'a str,
22578 account_guid: &'a str,
22579 transaction_guid: &'a str,
22580 ) -> Result<ResponseValue<()>, Error<()>> {
22581 let url = format!(
22582 "{}/users/{}/managed_members/{}/accounts/{}/transactions/{}",
22583 self.baseurl,
22584 encode_path(&user_guid.to_string()),
22585 encode_path(&member_guid.to_string()),
22586 encode_path(&account_guid.to_string()),
22587 encode_path(&transaction_guid.to_string()),
22588 );
22589 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
22590 header_map.append(
22591 ::reqwest::header::HeaderName::from_static("api-version"),
22592 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
22593 );
22594 #[allow(unused_mut)]
22595 let mut request = self.client.delete(url).headers(header_map).build()?;
22596 let info = OperationInfo {
22597 operation_id: "delete_managed_transaction",
22598 };
22599 self.pre(&mut request, &info).await?;
22600 let result = self.exec(request, &info).await;
22601 self.post(&result, &info).await?;
22602 let response = result?;
22603 match response.status().as_u16() {
22604 204u16 => Ok(ResponseValue::empty(response)),
22605 _ => Err(Error::UnexpectedResponse(response)),
22606 }
22607 }
22608
22609 ///List members
22610 ///
22611 ///This endpoint returns an array which contains information on every
22612 /// member associated with a specific user.
22613 ///
22614 ///Sends a `GET` request to `/users/{user_guid}/members`
22615 ///
22616 ///Arguments:
22617 /// - `user_guid`: The unique identifier for a `user`, beginning with the
22618 /// prefix `USR-`.
22619 /// - `page`: Results are paginated. Specify current page.
22620 /// - `records_per_page`: This specifies the number of records to be
22621 /// returned on each page. Defaults to `25`. The valid range is from `10`
22622 /// to `1000`. If the value exceeds `1000`, the default value of `25` will
22623 /// be used instead.
22624 /// - `use_case`: The use case associated with the member. Valid values are
22625 /// `PFM` and `MONEY_MOVEMENT`. For example, you can append either
22626 /// `?use_case=PFM` or `?use_case=MONEY_MOVEMENT`.
22627 pub async fn list_members<'a>(
22628 &'a self,
22629 user_guid: &'a str,
22630 page: Option<i64>,
22631 records_per_page: Option<i64>,
22632 use_case: Option<&'a str>,
22633 ) -> Result<ResponseValue<types::MembersResponseBody>, Error<()>> {
22634 let url = format!(
22635 "{}/users/{}/members",
22636 self.baseurl,
22637 encode_path(&user_guid.to_string()),
22638 );
22639 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
22640 header_map.append(
22641 ::reqwest::header::HeaderName::from_static("api-version"),
22642 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
22643 );
22644 #[allow(unused_mut)]
22645 let mut request = self
22646 .client
22647 .get(url)
22648 .header(
22649 ::reqwest::header::ACCEPT,
22650 ::reqwest::header::HeaderValue::from_static("application/json"),
22651 )
22652 .query(&progenitor_client::QueryParam::new("page", &page))
22653 .query(&progenitor_client::QueryParam::new(
22654 "records_per_page",
22655 &records_per_page,
22656 ))
22657 .query(&progenitor_client::QueryParam::new("use_case", &use_case))
22658 .headers(header_map)
22659 .build()?;
22660 let info = OperationInfo {
22661 operation_id: "list_members",
22662 };
22663 self.pre(&mut request, &info).await?;
22664 let result = self.exec(request, &info).await;
22665 self.post(&result, &info).await?;
22666 let response = result?;
22667 match response.status().as_u16() {
22668 200u16 => ResponseValue::from_response(response).await,
22669 _ => Err(Error::UnexpectedResponse(response)),
22670 }
22671 }
22672
22673 ///Create member
22674 ///
22675 ///This endpoint allows you to create a new member. Members are created
22676 /// with the required parameters credentials and institution_code, and the
22677 /// optional parameters id and metadata. When creating a member, youll need
22678 /// to include the correct type of credential required by the financial
22679 /// institution and provided by the user. You can find out which credential
22680 /// type is required with the `/institutions/{institution_code}/credentials`
22681 /// endpoint. If successful, the MX Platform API will respond with the
22682 /// newly-created member object. Once you successfully create a member, MX
22683 /// will immediately validate the provided credentials and attempt to
22684 /// aggregate data for accounts and transactions.
22685 ///
22686 ///Sends a `POST` request to `/users/{user_guid}/members`
22687 ///
22688 ///Arguments:
22689 /// - `user_guid`: The unique identifier for a `user`, beginning with the
22690 /// prefix `USR-`.
22691 /// - `x_callback_payload`: The base64 encoded string defined in this header
22692 /// will be returned in the [Member](/resources/webhooks/member/) and
22693 /// [Member Data Updated](/resources/webhooks/member#member-data-updated)
22694 /// webhooks. This allows you to trace user interactions and workflows
22695 /// initiated externally and internally in the MX Platform. Max 1024
22696 /// characters.
22697 /// - `body`: Member object to be created with optional parameters (id and
22698 /// metadata) and required parameters (credentials and institution_code)
22699 pub async fn create_member<'a>(
22700 &'a self,
22701 user_guid: &'a str,
22702 x_callback_payload: Option<&'a str>,
22703 body: &'a types::MemberCreateRequestBody,
22704 ) -> Result<ResponseValue<types::MemberResponseBody>, Error<()>> {
22705 let url = format!(
22706 "{}/users/{}/members",
22707 self.baseurl,
22708 encode_path(&user_guid.to_string()),
22709 );
22710 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(2usize);
22711 header_map.append(
22712 ::reqwest::header::HeaderName::from_static("api-version"),
22713 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
22714 );
22715 if let Some(value) = x_callback_payload {
22716 header_map.append("X-CALLBACK-PAYLOAD", value.to_string().try_into()?);
22717 }
22718
22719 #[allow(unused_mut)]
22720 let mut request = self
22721 .client
22722 .post(url)
22723 .header(
22724 ::reqwest::header::ACCEPT,
22725 ::reqwest::header::HeaderValue::from_static("application/json"),
22726 )
22727 .json(&body)
22728 .headers(header_map)
22729 .build()?;
22730 let info = OperationInfo {
22731 operation_id: "create_member",
22732 };
22733 self.pre(&mut request, &info).await?;
22734 let result = self.exec(request, &info).await;
22735 self.post(&result, &info).await?;
22736 let response = result?;
22737 match response.status().as_u16() {
22738 200u16 => ResponseValue::from_response(response).await,
22739 202u16 => ResponseValue::from_response(response).await,
22740 _ => Err(Error::UnexpectedResponse(response)),
22741 }
22742 }
22743
22744 ///Read member
22745 ///
22746 ///Use this endpoint to read the attributes of a specific member.
22747 ///
22748 ///Sends a `GET` request to `/users/{user_guid}/members/{member_guid}`
22749 ///
22750 ///Arguments:
22751 /// - `user_guid`: The unique identifier for a `user`, beginning with the
22752 /// prefix `USR-`.
22753 /// - `member_guid`: The unique id for a `member`.
22754 pub async fn read_member<'a>(
22755 &'a self,
22756 user_guid: &'a str,
22757 member_guid: &'a str,
22758 ) -> Result<ResponseValue<types::MemberResponseBody>, Error<()>> {
22759 let url = format!(
22760 "{}/users/{}/members/{}",
22761 self.baseurl,
22762 encode_path(&user_guid.to_string()),
22763 encode_path(&member_guid.to_string()),
22764 );
22765 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
22766 header_map.append(
22767 ::reqwest::header::HeaderName::from_static("api-version"),
22768 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
22769 );
22770 #[allow(unused_mut)]
22771 let mut request = self
22772 .client
22773 .get(url)
22774 .header(
22775 ::reqwest::header::ACCEPT,
22776 ::reqwest::header::HeaderValue::from_static("application/json"),
22777 )
22778 .headers(header_map)
22779 .build()?;
22780 let info = OperationInfo {
22781 operation_id: "read_member",
22782 };
22783 self.pre(&mut request, &info).await?;
22784 let result = self.exec(request, &info).await;
22785 self.post(&result, &info).await?;
22786 let response = result?;
22787 match response.status().as_u16() {
22788 200u16 => ResponseValue::from_response(response).await,
22789 _ => Err(Error::UnexpectedResponse(response)),
22790 }
22791 }
22792
22793 ///Update member
22794 ///
22795 ///Use this endpoint to update a members attributes. Only the credentials,
22796 /// id, and metadata parameters can be updated. To get a list of the
22797 /// required credentials for the member, use the list member credentials
22798 /// endpoint.
22799 ///
22800 ///Sends a `PUT` request to `/users/{user_guid}/members/{member_guid}`
22801 ///
22802 ///Arguments:
22803 /// - `user_guid`: The unique identifier for a `user`, beginning with the
22804 /// prefix `USR-`.
22805 /// - `member_guid`: The unique id for a `member`.
22806 /// - `x_callback_payload`: The base64 encoded string defined in this header
22807 /// will be returned in the [Member](/resources/webhooks/member/) and
22808 /// [Member Data Updated](/resources/webhooks/member#member-data-updated)
22809 /// webhooks. This allows you to trace user interactions and workflows
22810 /// initiated externally and internally in the MX Platform. Max 1024
22811 /// characters.
22812 /// - `body`: Member object to be updated (While no single parameter is
22813 /// required, the request body can't be empty)
22814 pub async fn update_member<'a>(
22815 &'a self,
22816 user_guid: &'a str,
22817 member_guid: &'a str,
22818 x_callback_payload: Option<&'a str>,
22819 body: &'a types::MemberUpdateRequestBody,
22820 ) -> Result<ResponseValue<types::MemberResponseBody>, Error<()>> {
22821 let url = format!(
22822 "{}/users/{}/members/{}",
22823 self.baseurl,
22824 encode_path(&user_guid.to_string()),
22825 encode_path(&member_guid.to_string()),
22826 );
22827 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(2usize);
22828 header_map.append(
22829 ::reqwest::header::HeaderName::from_static("api-version"),
22830 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
22831 );
22832 if let Some(value) = x_callback_payload {
22833 header_map.append("X-CALLBACK-PAYLOAD", value.to_string().try_into()?);
22834 }
22835
22836 #[allow(unused_mut)]
22837 let mut request = self
22838 .client
22839 .put(url)
22840 .header(
22841 ::reqwest::header::ACCEPT,
22842 ::reqwest::header::HeaderValue::from_static("application/json"),
22843 )
22844 .json(&body)
22845 .headers(header_map)
22846 .build()?;
22847 let info = OperationInfo {
22848 operation_id: "update_member",
22849 };
22850 self.pre(&mut request, &info).await?;
22851 let result = self.exec(request, &info).await;
22852 self.post(&result, &info).await?;
22853 let response = result?;
22854 match response.status().as_u16() {
22855 200u16 => ResponseValue::from_response(response).await,
22856 _ => Err(Error::UnexpectedResponse(response)),
22857 }
22858 }
22859
22860 ///Delete member
22861 ///
22862 ///Accessing this endpoint will permanently delete a member.
22863 ///
22864 ///Sends a `DELETE` request to `/users/{user_guid}/members/{member_guid}`
22865 ///
22866 ///Arguments:
22867 /// - `user_guid`: The unique identifier for a `user`, beginning with the
22868 /// prefix `USR-`.
22869 /// - `member_guid`: The unique id for a `member`.
22870 pub async fn delete_member<'a>(
22871 &'a self,
22872 user_guid: &'a str,
22873 member_guid: &'a str,
22874 ) -> Result<ResponseValue<()>, Error<()>> {
22875 let url = format!(
22876 "{}/users/{}/members/{}",
22877 self.baseurl,
22878 encode_path(&user_guid.to_string()),
22879 encode_path(&member_guid.to_string()),
22880 );
22881 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
22882 header_map.append(
22883 ::reqwest::header::HeaderName::from_static("api-version"),
22884 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
22885 );
22886 #[allow(unused_mut)]
22887 let mut request = self.client.delete(url).headers(header_map).build()?;
22888 let info = OperationInfo {
22889 operation_id: "delete_member",
22890 };
22891 self.pre(&mut request, &info).await?;
22892 let result = self.exec(request, &info).await;
22893 self.post(&result, &info).await?;
22894 let response = result?;
22895 match response.status().as_u16() {
22896 204u16 => Ok(ResponseValue::empty(response)),
22897 _ => Err(Error::UnexpectedResponse(response)),
22898 }
22899 }
22900
22901 ///List account numbers by member
22902 ///
22903 ///This endpoint returns a list of account numbers associated with the
22904 /// specified `member`.
22905 ///
22906 ///Sends a `GET` request to
22907 /// `/users/{user_guid}/members/{member_guid}/account_numbers`
22908 ///
22909 ///Arguments:
22910 /// - `user_guid`: The unique identifier for a `user`, beginning with the
22911 /// prefix `USR-`.
22912 /// - `member_guid`: The unique id for a `member`.
22913 /// - `page`: Results are paginated. Specify current page.
22914 /// - `records_per_page`: This specifies the number of records to be
22915 /// returned on each page. Defaults to `25`. The valid range is from `10`
22916 /// to `1000`. If the value exceeds `1000`, the default value of `25` will
22917 /// be used instead.
22918 pub async fn list_account_numbers_by_member<'a>(
22919 &'a self,
22920 user_guid: &'a str,
22921 member_guid: &'a str,
22922 page: Option<i64>,
22923 records_per_page: Option<i64>,
22924 ) -> Result<ResponseValue<types::AccountNumbersResponseBody>, Error<()>> {
22925 let url = format!(
22926 "{}/users/{}/members/{}/account_numbers",
22927 self.baseurl,
22928 encode_path(&user_guid.to_string()),
22929 encode_path(&member_guid.to_string()),
22930 );
22931 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
22932 header_map.append(
22933 ::reqwest::header::HeaderName::from_static("api-version"),
22934 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
22935 );
22936 #[allow(unused_mut)]
22937 let mut request = self
22938 .client
22939 .get(url)
22940 .header(
22941 ::reqwest::header::ACCEPT,
22942 ::reqwest::header::HeaderValue::from_static("application/json"),
22943 )
22944 .query(&progenitor_client::QueryParam::new("page", &page))
22945 .query(&progenitor_client::QueryParam::new(
22946 "records_per_page",
22947 &records_per_page,
22948 ))
22949 .headers(header_map)
22950 .build()?;
22951 let info = OperationInfo {
22952 operation_id: "list_account_numbers_by_member",
22953 };
22954 self.pre(&mut request, &info).await?;
22955 let result = self.exec(request, &info).await;
22956 self.post(&result, &info).await?;
22957 let response = result?;
22958 match response.status().as_u16() {
22959 200u16 => ResponseValue::from_response(response).await,
22960 _ => Err(Error::UnexpectedResponse(response)),
22961 }
22962 }
22963
22964 ///List account owners by member
22965 ///
22966 ///This endpoint returns an array with information about every account
22967 /// associated with a particular member.
22968 ///
22969 ///Sends a `GET` request to
22970 /// `/users/{user_guid}/members/{member_guid}/account_owners`
22971 ///
22972 ///Arguments:
22973 /// - `user_guid`: The unique identifier for a `user`, beginning with the
22974 /// prefix `USR-`.
22975 /// - `member_guid`: The unique id for a `member`.
22976 /// - `page`: Results are paginated. Specify current page.
22977 /// - `records_per_page`: This specifies the number of records to be
22978 /// returned on each page. Defaults to `25`. The valid range is from `10`
22979 /// to `1000`. If the value exceeds `1000`, the default value of `25` will
22980 /// be used instead.
22981 pub async fn list_account_owners_by_member<'a>(
22982 &'a self,
22983 user_guid: &'a str,
22984 member_guid: &'a str,
22985 page: Option<i64>,
22986 records_per_page: Option<i64>,
22987 ) -> Result<ResponseValue<types::AccountOwnersResponseBody>, Error<()>> {
22988 let url = format!(
22989 "{}/users/{}/members/{}/account_owners",
22990 self.baseurl,
22991 encode_path(&user_guid.to_string()),
22992 encode_path(&member_guid.to_string()),
22993 );
22994 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
22995 header_map.append(
22996 ::reqwest::header::HeaderName::from_static("api-version"),
22997 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
22998 );
22999 #[allow(unused_mut)]
23000 let mut request = self
23001 .client
23002 .get(url)
23003 .header(
23004 ::reqwest::header::ACCEPT,
23005 ::reqwest::header::HeaderValue::from_static("application/json"),
23006 )
23007 .query(&progenitor_client::QueryParam::new("page", &page))
23008 .query(&progenitor_client::QueryParam::new(
23009 "records_per_page",
23010 &records_per_page,
23011 ))
23012 .headers(header_map)
23013 .build()?;
23014 let info = OperationInfo {
23015 operation_id: "list_account_owners_by_member",
23016 };
23017 self.pre(&mut request, &info).await?;
23018 let result = self.exec(request, &info).await;
23019 self.post(&result, &info).await?;
23020 let response = result?;
23021 match response.status().as_u16() {
23022 200u16 => ResponseValue::from_response(response).await,
23023 _ => Err(Error::UnexpectedResponse(response)),
23024 }
23025 }
23026
23027 ///List accounts by member
23028 ///
23029 ///This endpoint returns a list of all the accounts associated with the
23030 /// specified `member`.
23031 ///
23032 ///Sends a `GET` request to
23033 /// `/users/{user_guid}/members/{member_guid}/accounts`
23034 ///
23035 ///Arguments:
23036 /// - `user_guid`: The unique identifier for a `user`, beginning with the
23037 /// prefix `USR-`.
23038 /// - `member_guid`: The unique id for a `member`.
23039 /// - `member_is_managed_by_user`: List only accounts whose member is
23040 /// managed by the user.
23041 /// - `page`: Results are paginated. Specify current page.
23042 /// - `records_per_page`: This specifies the number of records to be
23043 /// returned on each page. Defaults to `25`. The valid range is from `10`
23044 /// to `1000`. If the value exceeds `1000`, the default value of `25` will
23045 /// be used instead.
23046 pub async fn list_member_accounts<'a>(
23047 &'a self,
23048 user_guid: &'a str,
23049 member_guid: &'a str,
23050 member_is_managed_by_user: Option<bool>,
23051 page: Option<i64>,
23052 records_per_page: Option<i64>,
23053 ) -> Result<ResponseValue<types::AccountsResponseBody>, Error<()>> {
23054 let url = format!(
23055 "{}/users/{}/members/{}/accounts",
23056 self.baseurl,
23057 encode_path(&user_guid.to_string()),
23058 encode_path(&member_guid.to_string()),
23059 );
23060 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
23061 header_map.append(
23062 ::reqwest::header::HeaderName::from_static("api-version"),
23063 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
23064 );
23065 #[allow(unused_mut)]
23066 let mut request = self
23067 .client
23068 .get(url)
23069 .header(
23070 ::reqwest::header::ACCEPT,
23071 ::reqwest::header::HeaderValue::from_static("application/json"),
23072 )
23073 .query(&progenitor_client::QueryParam::new(
23074 "member_is_managed_by_user",
23075 &member_is_managed_by_user,
23076 ))
23077 .query(&progenitor_client::QueryParam::new("page", &page))
23078 .query(&progenitor_client::QueryParam::new(
23079 "records_per_page",
23080 &records_per_page,
23081 ))
23082 .headers(header_map)
23083 .build()?;
23084 let info = OperationInfo {
23085 operation_id: "list_member_accounts",
23086 };
23087 self.pre(&mut request, &info).await?;
23088 let result = self.exec(request, &info).await;
23089 self.post(&result, &info).await?;
23090 let response = result?;
23091 match response.status().as_u16() {
23092 200u16 => ResponseValue::from_response(response).await,
23093 _ => Err(Error::UnexpectedResponse(response)),
23094 }
23095 }
23096
23097 ///Read account by member
23098 ///
23099 ///This endpoint allows you to read the attributes of an `account`
23100 /// resource.
23101 ///
23102 ///Sends a `GET` request to
23103 /// `/users/{user_guid}/members/{member_guid}/accounts/{account_guid}`
23104 ///
23105 ///Arguments:
23106 /// - `user_guid`: The unique identifier for a `user`, beginning with the
23107 /// prefix `USR-`.
23108 /// - `member_guid`: The unique id for a `member`.
23109 /// - `account_guid`: The unique id for an `account`.
23110 pub async fn read_account_by_member<'a>(
23111 &'a self,
23112 user_guid: &'a str,
23113 member_guid: &'a str,
23114 account_guid: &'a str,
23115 ) -> Result<ResponseValue<types::AccountResponseBody>, Error<()>> {
23116 let url = format!(
23117 "{}/users/{}/members/{}/accounts/{}",
23118 self.baseurl,
23119 encode_path(&user_guid.to_string()),
23120 encode_path(&member_guid.to_string()),
23121 encode_path(&account_guid.to_string()),
23122 );
23123 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
23124 header_map.append(
23125 ::reqwest::header::HeaderName::from_static("api-version"),
23126 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
23127 );
23128 #[allow(unused_mut)]
23129 let mut request = self
23130 .client
23131 .get(url)
23132 .header(
23133 ::reqwest::header::ACCEPT,
23134 ::reqwest::header::HeaderValue::from_static("application/json"),
23135 )
23136 .headers(header_map)
23137 .build()?;
23138 let info = OperationInfo {
23139 operation_id: "read_account_by_member",
23140 };
23141 self.pre(&mut request, &info).await?;
23142 let result = self.exec(request, &info).await;
23143 self.post(&result, &info).await?;
23144 let response = result?;
23145 match response.status().as_u16() {
23146 200u16 => ResponseValue::from_response(response).await,
23147 _ => Err(Error::UnexpectedResponse(response)),
23148 }
23149 }
23150
23151 ///Update account by member
23152 ///
23153 ///This endpoint allows you to update certain attributes of an `account`
23154 /// resource, including manual accounts. For manual accounts, you can update
23155 /// every field listed. For aggregated accounts, you can only update
23156 /// `is_business`, `is_hidden` and `metadata`.
23157 ///
23158 ///Sends a `PUT` request to
23159 /// `/users/{user_guid}/members/{member_guid}/accounts/{account_guid}`
23160 ///
23161 ///Arguments:
23162 /// - `user_guid`: The unique identifier for a `user`, beginning with the
23163 /// prefix `USR-`.
23164 /// - `member_guid`: The unique id for a `member`.
23165 /// - `account_guid`: The unique id for an `account`.
23166 /// - `body`
23167 pub async fn update_account_by_member<'a>(
23168 &'a self,
23169 user_guid: &'a str,
23170 member_guid: &'a str,
23171 account_guid: &'a str,
23172 body: &'a types::AccountUpdateRequestBody,
23173 ) -> Result<ResponseValue<types::AccountResponseBody>, Error<()>> {
23174 let url = format!(
23175 "{}/users/{}/members/{}/accounts/{}",
23176 self.baseurl,
23177 encode_path(&user_guid.to_string()),
23178 encode_path(&member_guid.to_string()),
23179 encode_path(&account_guid.to_string()),
23180 );
23181 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
23182 header_map.append(
23183 ::reqwest::header::HeaderName::from_static("api-version"),
23184 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
23185 );
23186 #[allow(unused_mut)]
23187 let mut request = self
23188 .client
23189 .put(url)
23190 .header(
23191 ::reqwest::header::ACCEPT,
23192 ::reqwest::header::HeaderValue::from_static("application/json"),
23193 )
23194 .json(&body)
23195 .headers(header_map)
23196 .build()?;
23197 let info = OperationInfo {
23198 operation_id: "update_account_by_member",
23199 };
23200 self.pre(&mut request, &info).await?;
23201 let result = self.exec(request, &info).await;
23202 self.post(&result, &info).await?;
23203 let response = result?;
23204 match response.status().as_u16() {
23205 200u16 => ResponseValue::from_response(response).await,
23206 _ => Err(Error::UnexpectedResponse(response)),
23207 }
23208 }
23209
23210 ///Update Transaction by Account
23211 ///
23212 ///Use this endpoint to update a specific transaction according to its
23213 /// unique GUID.
23214 ///
23215 ///Sends a `PUT` request to
23216 /// `/users/{user_guid}/members/{member_guid}/accounts/{account_guid}/
23217 /// transactions/{transaction_guid}`
23218 ///
23219 ///Arguments:
23220 /// - `user_guid`: The unique identifier for a `user`, beginning with the
23221 /// prefix `USR-`.
23222 /// - `member_guid`: The unique id for a `member`.
23223 /// - `account_guid`: The unique id for an `account`.
23224 /// - `transaction_guid`: The unique id for a `transaction`.
23225 /// - `body`: Transaction object to be updated
23226 pub async fn update_transaction_by_account<'a>(
23227 &'a self,
23228 user_guid: &'a str,
23229 member_guid: &'a str,
23230 account_guid: &'a str,
23231 transaction_guid: &'a str,
23232 body: &'a types::TransactionUpdateRequestBody,
23233 ) -> Result<ResponseValue<types::TransactionResponseBody>, Error<()>> {
23234 let url = format!(
23235 "{}/users/{}/members/{}/accounts/{}/transactions/{}",
23236 self.baseurl,
23237 encode_path(&user_guid.to_string()),
23238 encode_path(&member_guid.to_string()),
23239 encode_path(&account_guid.to_string()),
23240 encode_path(&transaction_guid.to_string()),
23241 );
23242 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
23243 header_map.append(
23244 ::reqwest::header::HeaderName::from_static("api-version"),
23245 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
23246 );
23247 #[allow(unused_mut)]
23248 let mut request = self
23249 .client
23250 .put(url)
23251 .header(
23252 ::reqwest::header::ACCEPT,
23253 ::reqwest::header::HeaderValue::from_static("application/json"),
23254 )
23255 .json(&body)
23256 .headers(header_map)
23257 .build()?;
23258 let info = OperationInfo {
23259 operation_id: "update_transaction_by_account",
23260 };
23261 self.pre(&mut request, &info).await?;
23262 let result = self.exec(request, &info).await;
23263 self.post(&result, &info).await?;
23264 let response = result?;
23265 match response.status().as_u16() {
23266 200u16 => ResponseValue::from_response(response).await,
23267 _ => Err(Error::UnexpectedResponse(response)),
23268 }
23269 }
23270
23271 ///Aggregate member
23272 ///
23273 ///Calling this endpoint initiates an aggregation event for the member.
23274 /// This brings in the latest account and transaction data from the
23275 /// connected institution. If this data has recently been updated, MX may
23276 /// not initiate an aggregation event.
23277 ///
23278 ///Sends a `POST` request to
23279 /// `/users/{user_guid}/members/{member_guid}/aggregate`
23280 ///
23281 ///Arguments:
23282 /// - `user_guid`: The unique identifier for a `user`, beginning with the
23283 /// prefix `USR-`.
23284 /// - `member_guid`: The unique id for a `member`.
23285 /// - `include_holdings`: When set to `false`, the aggregation will not
23286 /// gather holdings data. Defaults to `true`.
23287 /// - `include_transactions`: When set to `false`, the aggregation will not
23288 /// gather transactions data. Defaults to `true`.
23289 /// - `x_callback_payload`: The base64 encoded string defined in this header
23290 /// will be returned in the [Member](/resources/webhooks/member/) and
23291 /// [Member Data Updated](/resources/webhooks/member#member-data-updated)
23292 /// webhooks. This allows you to trace user interactions and workflows
23293 /// initiated externally and internally in the MX Platform. Max 1024
23294 /// characters.
23295 pub async fn aggregate_member<'a>(
23296 &'a self,
23297 user_guid: &'a str,
23298 member_guid: &'a str,
23299 include_holdings: Option<bool>,
23300 include_transactions: Option<bool>,
23301 x_callback_payload: Option<&'a str>,
23302 ) -> Result<ResponseValue<types::MemberResponseBody>, Error<()>> {
23303 let url = format!(
23304 "{}/users/{}/members/{}/aggregate",
23305 self.baseurl,
23306 encode_path(&user_guid.to_string()),
23307 encode_path(&member_guid.to_string()),
23308 );
23309 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(2usize);
23310 header_map.append(
23311 ::reqwest::header::HeaderName::from_static("api-version"),
23312 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
23313 );
23314 if let Some(value) = x_callback_payload {
23315 header_map.append("X-CALLBACK-PAYLOAD", value.to_string().try_into()?);
23316 }
23317
23318 #[allow(unused_mut)]
23319 let mut request = self
23320 .client
23321 .post(url)
23322 .header(
23323 ::reqwest::header::ACCEPT,
23324 ::reqwest::header::HeaderValue::from_static("application/json"),
23325 )
23326 .query(&progenitor_client::QueryParam::new(
23327 "include_holdings",
23328 &include_holdings,
23329 ))
23330 .query(&progenitor_client::QueryParam::new(
23331 "include_transactions",
23332 &include_transactions,
23333 ))
23334 .headers(header_map)
23335 .build()?;
23336 let info = OperationInfo {
23337 operation_id: "aggregate_member",
23338 };
23339 self.pre(&mut request, &info).await?;
23340 let result = self.exec(request, &info).await;
23341 self.post(&result, &info).await?;
23342 let response = result?;
23343 match response.status().as_u16() {
23344 202u16 => ResponseValue::from_response(response).await,
23345 _ => Err(Error::UnexpectedResponse(response)),
23346 }
23347 }
23348
23349 ///List member challenges
23350 ///
23351 ///Use this endpoint for information on what multi-factor authentication
23352 /// challenges need to be answered in order to aggregate a member. If the
23353 /// aggregation is not challenged, i.e., the member does not have a
23354 /// connection status of `CHALLENGED`, then code `204 No Content` will be
23355 /// returned. If the aggregation has been challenged, i.e., the member does
23356 /// have a connection status of `CHALLENGED`, then code `200 OK` will be
23357 /// returned - along with the corresponding credentials.
23358 ///
23359 ///Sends a `GET` request to
23360 /// `/users/{user_guid}/members/{member_guid}/challenges`
23361 ///
23362 ///Arguments:
23363 /// - `user_guid`: The unique identifier for a `user`, beginning with the
23364 /// prefix `USR-`.
23365 /// - `member_guid`: The unique id for a `member`.
23366 /// - `page`: Results are paginated. Specify current page.
23367 /// - `records_per_page`: This specifies the number of records to be
23368 /// returned on each page. Defaults to `25`. The valid range is from `10`
23369 /// to `1000`. If the value exceeds `1000`, the default value of `25` will
23370 /// be used instead.
23371 pub async fn list_member_challenges<'a>(
23372 &'a self,
23373 user_guid: &'a str,
23374 member_guid: &'a str,
23375 page: Option<i64>,
23376 records_per_page: Option<i64>,
23377 ) -> Result<ResponseValue<types::ChallengesResponseBody>, Error<()>> {
23378 let url = format!(
23379 "{}/users/{}/members/{}/challenges",
23380 self.baseurl,
23381 encode_path(&user_guid.to_string()),
23382 encode_path(&member_guid.to_string()),
23383 );
23384 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
23385 header_map.append(
23386 ::reqwest::header::HeaderName::from_static("api-version"),
23387 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
23388 );
23389 #[allow(unused_mut)]
23390 let mut request = self
23391 .client
23392 .get(url)
23393 .header(
23394 ::reqwest::header::ACCEPT,
23395 ::reqwest::header::HeaderValue::from_static("application/json"),
23396 )
23397 .query(&progenitor_client::QueryParam::new("page", &page))
23398 .query(&progenitor_client::QueryParam::new(
23399 "records_per_page",
23400 &records_per_page,
23401 ))
23402 .headers(header_map)
23403 .build()?;
23404 let info = OperationInfo {
23405 operation_id: "list_member_challenges",
23406 };
23407 self.pre(&mut request, &info).await?;
23408 let result = self.exec(request, &info).await;
23409 self.post(&result, &info).await?;
23410 let response = result?;
23411 match response.status().as_u16() {
23412 200u16 => ResponseValue::from_response(response).await,
23413 _ => Err(Error::UnexpectedResponse(response)),
23414 }
23415 }
23416
23417 ///Check balances
23418 ///
23419 ///This endpoint operates much like the aggregate member endpoint except
23420 /// that it gathers only account balance information; it does not gather any
23421 /// transaction data.
23422 ///
23423 ///Sends a `POST` request to
23424 /// `/users/{user_guid}/members/{member_guid}/check_balance`
23425 ///
23426 ///Arguments:
23427 /// - `user_guid`: The unique identifier for a `user`, beginning with the
23428 /// prefix `USR-`.
23429 /// - `member_guid`: The unique id for a `member`.
23430 pub async fn check_balances<'a>(
23431 &'a self,
23432 user_guid: &'a str,
23433 member_guid: &'a str,
23434 ) -> Result<ResponseValue<types::MemberResponseBody>, Error<()>> {
23435 let url = format!(
23436 "{}/users/{}/members/{}/check_balance",
23437 self.baseurl,
23438 encode_path(&user_guid.to_string()),
23439 encode_path(&member_guid.to_string()),
23440 );
23441 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
23442 header_map.append(
23443 ::reqwest::header::HeaderName::from_static("api-version"),
23444 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
23445 );
23446 #[allow(unused_mut)]
23447 let mut request = self
23448 .client
23449 .post(url)
23450 .header(
23451 ::reqwest::header::ACCEPT,
23452 ::reqwest::header::HeaderValue::from_static("application/json"),
23453 )
23454 .headers(header_map)
23455 .build()?;
23456 let info = OperationInfo {
23457 operation_id: "check_balances",
23458 };
23459 self.pre(&mut request, &info).await?;
23460 let result = self.exec(request, &info).await;
23461 self.post(&result, &info).await?;
23462 let response = result?;
23463 match response.status().as_u16() {
23464 202u16 => ResponseValue::from_response(response).await,
23465 _ => Err(Error::UnexpectedResponse(response)),
23466 }
23467 }
23468
23469 ///List member credentials
23470 ///
23471 ///This endpoint returns an array which contains information on every
23472 /// non-MFA credential associated with a specific member.
23473 ///
23474 ///Sends a `GET` request to
23475 /// `/users/{user_guid}/members/{member_guid}/credentials`
23476 ///
23477 ///Arguments:
23478 /// - `user_guid`: The unique identifier for a `user`, beginning with the
23479 /// prefix `USR-`.
23480 /// - `member_guid`: The unique id for a `member`.
23481 /// - `page`: Results are paginated. Specify current page.
23482 /// - `records_per_page`: This specifies the number of records to be
23483 /// returned on each page. Defaults to `25`. The valid range is from `10`
23484 /// to `1000`. If the value exceeds `1000`, the default value of `25` will
23485 /// be used instead.
23486 pub async fn list_member_credentials<'a>(
23487 &'a self,
23488 user_guid: &'a str,
23489 member_guid: &'a str,
23490 page: Option<i64>,
23491 records_per_page: Option<i64>,
23492 ) -> Result<ResponseValue<types::CredentialsResponseBody>, Error<()>> {
23493 let url = format!(
23494 "{}/users/{}/members/{}/credentials",
23495 self.baseurl,
23496 encode_path(&user_guid.to_string()),
23497 encode_path(&member_guid.to_string()),
23498 );
23499 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
23500 header_map.append(
23501 ::reqwest::header::HeaderName::from_static("api-version"),
23502 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
23503 );
23504 #[allow(unused_mut)]
23505 let mut request = self
23506 .client
23507 .get(url)
23508 .header(
23509 ::reqwest::header::ACCEPT,
23510 ::reqwest::header::HeaderValue::from_static("application/json"),
23511 )
23512 .query(&progenitor_client::QueryParam::new("page", &page))
23513 .query(&progenitor_client::QueryParam::new(
23514 "records_per_page",
23515 &records_per_page,
23516 ))
23517 .headers(header_map)
23518 .build()?;
23519 let info = OperationInfo {
23520 operation_id: "list_member_credentials",
23521 };
23522 self.pre(&mut request, &info).await?;
23523 let result = self.exec(request, &info).await;
23524 self.post(&result, &info).await?;
23525 let response = result?;
23526 match response.status().as_u16() {
23527 200u16 => ResponseValue::from_response(response).await,
23528 _ => Err(Error::UnexpectedResponse(response)),
23529 }
23530 }
23531
23532 ///Extend history
23533 ///
23534 ///Some institutions allow developers to access an extended transaction
23535 /// history with up to 24 months of data associated with a particular
23536 /// member. The process for fetching and then reading this extended
23537 /// transaction history is much like standard aggregation, and it may
23538 /// trigger multi-factor authentication.
23539 ///
23540 ///Sends a `POST` request to
23541 /// `/users/{user_guid}/members/{member_guid}/extend_history`
23542 ///
23543 ///Arguments:
23544 /// - `user_guid`: The unique identifier for a `user`, beginning with the
23545 /// prefix `USR-`.
23546 /// - `member_guid`: The unique id for a `member`.
23547 pub async fn extend_history<'a>(
23548 &'a self,
23549 user_guid: &'a str,
23550 member_guid: &'a str,
23551 ) -> Result<ResponseValue<types::MemberResponseBody>, Error<()>> {
23552 let url = format!(
23553 "{}/users/{}/members/{}/extend_history",
23554 self.baseurl,
23555 encode_path(&user_guid.to_string()),
23556 encode_path(&member_guid.to_string()),
23557 );
23558 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
23559 header_map.append(
23560 ::reqwest::header::HeaderName::from_static("api-version"),
23561 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
23562 );
23563 #[allow(unused_mut)]
23564 let mut request = self
23565 .client
23566 .post(url)
23567 .header(
23568 ::reqwest::header::ACCEPT,
23569 ::reqwest::header::HeaderValue::from_static("application/json"),
23570 )
23571 .headers(header_map)
23572 .build()?;
23573 let info = OperationInfo {
23574 operation_id: "extend_history",
23575 };
23576 self.pre(&mut request, &info).await?;
23577 let result = self.exec(request, &info).await;
23578 self.post(&result, &info).await?;
23579 let response = result?;
23580 match response.status().as_u16() {
23581 202u16 => ResponseValue::from_response(response).await,
23582 _ => Err(Error::UnexpectedResponse(response)),
23583 }
23584 }
23585
23586 ///Fetch statements
23587 ///
23588 ///Use this endpoint to fetch the statements associated with a particular
23589 /// member.
23590 ///
23591 ///Sends a `POST` request to
23592 /// `/users/{user_guid}/members/{member_guid}/fetch_statements`
23593 ///
23594 ///Arguments:
23595 /// - `user_guid`: The unique identifier for a `user`, beginning with the
23596 /// prefix `USR-`.
23597 /// - `member_guid`: The unique id for a `member`.
23598 pub async fn fetch_statements<'a>(
23599 &'a self,
23600 user_guid: &'a str,
23601 member_guid: &'a str,
23602 ) -> Result<ResponseValue<types::MemberResponseBody>, Error<()>> {
23603 let url = format!(
23604 "{}/users/{}/members/{}/fetch_statements",
23605 self.baseurl,
23606 encode_path(&user_guid.to_string()),
23607 encode_path(&member_guid.to_string()),
23608 );
23609 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
23610 header_map.append(
23611 ::reqwest::header::HeaderName::from_static("api-version"),
23612 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
23613 );
23614 #[allow(unused_mut)]
23615 let mut request = self
23616 .client
23617 .post(url)
23618 .header(
23619 ::reqwest::header::ACCEPT,
23620 ::reqwest::header::HeaderValue::from_static("application/json"),
23621 )
23622 .headers(header_map)
23623 .build()?;
23624 let info = OperationInfo {
23625 operation_id: "fetch_statements",
23626 };
23627 self.pre(&mut request, &info).await?;
23628 let result = self.exec(request, &info).await;
23629 self.post(&result, &info).await?;
23630 let response = result?;
23631 match response.status().as_u16() {
23632 202u16 => ResponseValue::from_response(response).await,
23633 _ => Err(Error::UnexpectedResponse(response)),
23634 }
23635 }
23636
23637 ///List holdings by member
23638 ///
23639 ///This endpoint lists all holdings associated with the specified member.
23640 ///
23641 ///Sends a `GET` request to
23642 /// `/users/{user_guid}/members/{member_guid}/investment_holdings`
23643 ///
23644 ///Arguments:
23645 /// - `user_guid`: The unique identifier for a `user`, beginning with the
23646 /// prefix `USR-`.
23647 /// - `member_guid`: The unique id for a `member`.
23648 /// - `page`: Results are paginated. Specify current page.
23649 /// - `records_per_page`: This specifies the number of records to be
23650 /// returned on each page. Defaults to `25`. The valid range is from `10`
23651 /// to `1000`. If the value exceeds `1000`, the default value of `25` will
23652 /// be used instead.
23653 pub async fn list_holdings_by_member<'a>(
23654 &'a self,
23655 user_guid: &'a str,
23656 member_guid: &'a str,
23657 page: Option<i64>,
23658 records_per_page: Option<i64>,
23659 ) -> Result<ResponseValue<types::InvestmentHoldingsResponseBody>, Error<()>> {
23660 let url = format!(
23661 "{}/users/{}/members/{}/investment_holdings",
23662 self.baseurl,
23663 encode_path(&user_guid.to_string()),
23664 encode_path(&member_guid.to_string()),
23665 );
23666 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
23667 header_map.append(
23668 ::reqwest::header::HeaderName::from_static("api-version"),
23669 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
23670 );
23671 #[allow(unused_mut)]
23672 let mut request = self
23673 .client
23674 .get(url)
23675 .header(
23676 ::reqwest::header::ACCEPT,
23677 ::reqwest::header::HeaderValue::from_static("application/json"),
23678 )
23679 .query(&progenitor_client::QueryParam::new("page", &page))
23680 .query(&progenitor_client::QueryParam::new(
23681 "records_per_page",
23682 &records_per_page,
23683 ))
23684 .headers(header_map)
23685 .build()?;
23686 let info = OperationInfo {
23687 operation_id: "list_holdings_by_member",
23688 };
23689 self.pre(&mut request, &info).await?;
23690 let result = self.exec(request, &info).await;
23691 self.post(&result, &info).await?;
23692 let response = result?;
23693 match response.status().as_u16() {
23694 200u16 => ResponseValue::from_response(response).await,
23695 _ => Err(Error::UnexpectedResponse(response)),
23696 }
23697 }
23698
23699 ///List holdings by user
23700 ///
23701 ///This endpoint lists all holdings associated with the user across all
23702 /// accounts.
23703 ///
23704 ///Sends a `GET` request to `/users/{user_guid}/investment_holdings`
23705 ///
23706 ///Arguments:
23707 /// - `user_guid`: The unique identifier for a `user`, beginning with the
23708 /// prefix `USR-`.
23709 /// - `page`: Results are paginated. Specify current page.
23710 /// - `records_per_page`: This specifies the number of records to be
23711 /// returned on each page. Defaults to `25`. The valid range is from `10`
23712 /// to `1000`. If the value exceeds `1000`, the default value of `25` will
23713 /// be used instead.
23714 pub async fn list_holdings<'a>(
23715 &'a self,
23716 user_guid: &'a str,
23717 page: Option<i64>,
23718 records_per_page: Option<i64>,
23719 ) -> Result<ResponseValue<types::InvestmentHoldingsResponseBody>, Error<()>> {
23720 let url = format!(
23721 "{}/users/{}/investment_holdings",
23722 self.baseurl,
23723 encode_path(&user_guid.to_string()),
23724 );
23725 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
23726 header_map.append(
23727 ::reqwest::header::HeaderName::from_static("api-version"),
23728 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
23729 );
23730 #[allow(unused_mut)]
23731 let mut request = self
23732 .client
23733 .get(url)
23734 .header(
23735 ::reqwest::header::ACCEPT,
23736 ::reqwest::header::HeaderValue::from_static("application/json"),
23737 )
23738 .query(&progenitor_client::QueryParam::new("page", &page))
23739 .query(&progenitor_client::QueryParam::new(
23740 "records_per_page",
23741 &records_per_page,
23742 ))
23743 .headers(header_map)
23744 .build()?;
23745 let info = OperationInfo {
23746 operation_id: "list_holdings",
23747 };
23748 self.pre(&mut request, &info).await?;
23749 let result = self.exec(request, &info).await;
23750 self.post(&result, &info).await?;
23751 let response = result?;
23752 match response.status().as_u16() {
23753 200u16 => ResponseValue::from_response(response).await,
23754 _ => Err(Error::UnexpectedResponse(response)),
23755 }
23756 }
23757
23758 ///Read holding
23759 ///
23760 ///Use this endpoint to read the attributes of a specific `holding`.
23761 ///
23762 ///Sends a `GET` request to
23763 /// `/users/{user_guid}/investment_holdings/{holding_guid}`
23764 ///
23765 ///Arguments:
23766 /// - `user_guid`: The unique identifier for a `user`, beginning with the
23767 /// prefix `USR-`.
23768 /// - `holding_guid`: The unique id for a `holding`.
23769 pub async fn read_holding<'a>(
23770 &'a self,
23771 user_guid: &'a str,
23772 holding_guid: &'a str,
23773 ) -> Result<ResponseValue<types::InvestmentHoldingResponseBody>, Error<()>> {
23774 let url = format!(
23775 "{}/users/{}/investment_holdings/{}",
23776 self.baseurl,
23777 encode_path(&user_guid.to_string()),
23778 encode_path(&holding_guid.to_string()),
23779 );
23780 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
23781 header_map.append(
23782 ::reqwest::header::HeaderName::from_static("api-version"),
23783 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
23784 );
23785 #[allow(unused_mut)]
23786 let mut request = self
23787 .client
23788 .get(url)
23789 .header(
23790 ::reqwest::header::ACCEPT,
23791 ::reqwest::header::HeaderValue::from_static("application/json"),
23792 )
23793 .headers(header_map)
23794 .build()?;
23795 let info = OperationInfo {
23796 operation_id: "read_holding",
23797 };
23798 self.pre(&mut request, &info).await?;
23799 let result = self.exec(request, &info).await;
23800 self.post(&result, &info).await?;
23801 let response = result?;
23802 match response.status().as_u16() {
23803 200u16 => ResponseValue::from_response(response).await,
23804 _ => Err(Error::UnexpectedResponse(response)),
23805 }
23806 }
23807
23808 ///List holdings by account
23809 ///
23810 ///This endpoint lists all holdings associated with the particular account
23811 /// defined.
23812 ///
23813 ///Sends a `GET` request to
23814 /// `/users/{user_guid}/accounts/{account_guid}/investment_holdings`
23815 ///
23816 ///Arguments:
23817 /// - `user_guid`: The unique identifier for a `user`, beginning with the
23818 /// prefix `USR-`.
23819 /// - `account_guid`: The unique id for an `account`.
23820 /// - `page`: Results are paginated. Specify current page.
23821 /// - `records_per_page`: This specifies the number of records to be
23822 /// returned on each page. Defaults to `25`. The valid range is from `10`
23823 /// to `1000`. If the value exceeds `1000`, the default value of `25` will
23824 /// be used instead.
23825 pub async fn list_holdings_by_account<'a>(
23826 &'a self,
23827 user_guid: &'a str,
23828 account_guid: &'a str,
23829 page: Option<i64>,
23830 records_per_page: Option<i64>,
23831 ) -> Result<ResponseValue<types::InvestmentHoldingsResponseBody>, Error<()>> {
23832 let url = format!(
23833 "{}/users/{}/accounts/{}/investment_holdings",
23834 self.baseurl,
23835 encode_path(&user_guid.to_string()),
23836 encode_path(&account_guid.to_string()),
23837 );
23838 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
23839 header_map.append(
23840 ::reqwest::header::HeaderName::from_static("api-version"),
23841 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
23842 );
23843 #[allow(unused_mut)]
23844 let mut request = self
23845 .client
23846 .get(url)
23847 .header(
23848 ::reqwest::header::ACCEPT,
23849 ::reqwest::header::HeaderValue::from_static("application/json"),
23850 )
23851 .query(&progenitor_client::QueryParam::new("page", &page))
23852 .query(&progenitor_client::QueryParam::new(
23853 "records_per_page",
23854 &records_per_page,
23855 ))
23856 .headers(header_map)
23857 .build()?;
23858 let info = OperationInfo {
23859 operation_id: "list_holdings_by_account",
23860 };
23861 self.pre(&mut request, &info).await?;
23862 let result = self.exec(request, &info).await;
23863 self.post(&result, &info).await?;
23864 let response = result?;
23865 match response.status().as_u16() {
23866 200u16 => ResponseValue::from_response(response).await,
23867 _ => Err(Error::UnexpectedResponse(response)),
23868 }
23869 }
23870
23871 ///Deactivate user from Investment Holdings
23872 ///
23873 ///This endpoint deactivates the specific user from the
23874 /// `/investment_holdings` product. To reactivate a user, use any of the
23875 /// current `/investment_holding` endpoints.
23876 ///
23877 ///Sends a `GET` request to
23878 /// `/users/{user_guid}/investment_holdings_deactivate`
23879 ///
23880 ///Arguments:
23881 /// - `user_guid`: The unique identifier for a `user`, beginning with the
23882 /// prefix `USR-`.
23883 pub async fn deactivate_user<'a>(
23884 &'a self,
23885 user_guid: &'a str,
23886 ) -> Result<ResponseValue<types::InvestmentHoldingsDeactivation>, Error<()>> {
23887 let url = format!(
23888 "{}/users/{}/investment_holdings_deactivate",
23889 self.baseurl,
23890 encode_path(&user_guid.to_string()),
23891 );
23892 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
23893 header_map.append(
23894 ::reqwest::header::HeaderName::from_static("api-version"),
23895 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
23896 );
23897 #[allow(unused_mut)]
23898 let mut request = self
23899 .client
23900 .get(url)
23901 .header(
23902 ::reqwest::header::ACCEPT,
23903 ::reqwest::header::HeaderValue::from_static("application/json"),
23904 )
23905 .headers(header_map)
23906 .build()?;
23907 let info = OperationInfo {
23908 operation_id: "deactivate_user",
23909 };
23910 self.pre(&mut request, &info).await?;
23911 let result = self.exec(request, &info).await;
23912 self.post(&result, &info).await?;
23913 let response = result?;
23914 match response.status().as_u16() {
23915 200u16 => ResponseValue::from_response(response).await,
23916 _ => Err(Error::UnexpectedResponse(response)),
23917 }
23918 }
23919
23920 ///Identify member
23921 ///
23922 ///The identify endpoint begins an identification process for an
23923 /// already-existing member.
23924 ///
23925 ///Sends a `POST` request to
23926 /// `/users/{user_guid}/members/{member_guid}/identify`
23927 ///
23928 ///Arguments:
23929 /// - `user_guid`: The unique identifier for a `user`, beginning with the
23930 /// prefix `USR-`.
23931 /// - `member_guid`: The unique id for a `member`.
23932 pub async fn identify_member<'a>(
23933 &'a self,
23934 user_guid: &'a str,
23935 member_guid: &'a str,
23936 ) -> Result<ResponseValue<types::MemberResponseBody>, Error<()>> {
23937 let url = format!(
23938 "{}/users/{}/members/{}/identify",
23939 self.baseurl,
23940 encode_path(&user_guid.to_string()),
23941 encode_path(&member_guid.to_string()),
23942 );
23943 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
23944 header_map.append(
23945 ::reqwest::header::HeaderName::from_static("api-version"),
23946 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
23947 );
23948 #[allow(unused_mut)]
23949 let mut request = self
23950 .client
23951 .post(url)
23952 .header(
23953 ::reqwest::header::ACCEPT,
23954 ::reqwest::header::HeaderValue::from_static("application/json"),
23955 )
23956 .headers(header_map)
23957 .build()?;
23958 let info = OperationInfo {
23959 operation_id: "identify_member",
23960 };
23961 self.pre(&mut request, &info).await?;
23962 let result = self.exec(request, &info).await;
23963 self.post(&result, &info).await?;
23964 let response = result?;
23965 match response.status().as_u16() {
23966 202u16 => ResponseValue::from_response(response).await,
23967 _ => Err(Error::UnexpectedResponse(response)),
23968 }
23969 }
23970
23971 ///Request oauth window uri
23972 ///
23973 ///This endpoint will generate an `oauth_window_uri` for the specified
23974 /// `member`.
23975 ///
23976 ///Sends a `GET` request to
23977 /// `/users/{user_guid}/members/{member_guid}/oauth_window_uri`
23978 ///
23979 ///Arguments:
23980 /// - `user_guid`: The unique identifier for a `user`, beginning with the
23981 /// prefix `USR-`.
23982 /// - `member_guid`: The unique id for a `member`.
23983 /// - `client_redirect_url`: A URL that MX will redirect to at the end of
23984 /// OAuth with additional query parameters. Only available with
23985 /// `referral_source=APP`.
23986 /// - `enable_app2app`: This indicates whether OAuth app2app behavior is
23987 /// enabled for institutions that support it. Defaults to `true`. When set
23988 /// to `false`, any `oauth_window_uri` generated will **not** direct the
23989 /// end user to the institution's mobile application. This setting is not
23990 /// persistent. This setting currently only affects Chase institutions.
23991 /// - `referral_source`: Must be either `BROWSER` or `APP` depending on the
23992 /// implementation. Defaults to `BROWSER`.
23993 /// - `skip_aggregation`: Setting this parameter to `true` will prevent the
23994 /// member from automatically aggregating after being redirected from the
23995 /// authorization page.
23996 /// - `ui_message_webview_url_scheme`: A scheme for routing the user back to
23997 /// the application state they were previously in. Only available with
23998 /// `referral_source=APP`.
23999 pub async fn request_o_auth_window_uri<'a>(
24000 &'a self,
24001 user_guid: &'a str,
24002 member_guid: &'a str,
24003 client_redirect_url: Option<&'a str>,
24004 enable_app2app: Option<&'a str>,
24005 referral_source: Option<&'a str>,
24006 skip_aggregation: Option<bool>,
24007 ui_message_webview_url_scheme: Option<&'a str>,
24008 ) -> Result<ResponseValue<types::OAuthWindowResponseBody>, Error<()>> {
24009 let url = format!(
24010 "{}/users/{}/members/{}/oauth_window_uri",
24011 self.baseurl,
24012 encode_path(&user_guid.to_string()),
24013 encode_path(&member_guid.to_string()),
24014 );
24015 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
24016 header_map.append(
24017 ::reqwest::header::HeaderName::from_static("api-version"),
24018 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
24019 );
24020 #[allow(unused_mut)]
24021 let mut request = self
24022 .client
24023 .get(url)
24024 .header(
24025 ::reqwest::header::ACCEPT,
24026 ::reqwest::header::HeaderValue::from_static("application/json"),
24027 )
24028 .query(&progenitor_client::QueryParam::new(
24029 "client_redirect_url",
24030 &client_redirect_url,
24031 ))
24032 .query(&progenitor_client::QueryParam::new(
24033 "enable_app2app",
24034 &enable_app2app,
24035 ))
24036 .query(&progenitor_client::QueryParam::new(
24037 "referral_source",
24038 &referral_source,
24039 ))
24040 .query(&progenitor_client::QueryParam::new(
24041 "skip_aggregation",
24042 &skip_aggregation,
24043 ))
24044 .query(&progenitor_client::QueryParam::new(
24045 "ui_message_webview_url_scheme",
24046 &ui_message_webview_url_scheme,
24047 ))
24048 .headers(header_map)
24049 .build()?;
24050 let info = OperationInfo {
24051 operation_id: "request_o_auth_window_uri",
24052 };
24053 self.pre(&mut request, &info).await?;
24054 let result = self.exec(request, &info).await;
24055 self.post(&result, &info).await?;
24056 let response = result?;
24057 match response.status().as_u16() {
24058 200u16 => ResponseValue::from_response(response).await,
24059 _ => Err(Error::UnexpectedResponse(response)),
24060 }
24061 }
24062
24063 ///Resume aggregation
24064 ///
24065 ///This endpoint answers the challenges needed when a member has been
24066 /// challenged by multi-factor authentication.
24067 ///
24068 ///Sends a `PUT` request to
24069 /// `/users/{user_guid}/members/{member_guid}/resume`
24070 ///
24071 ///Arguments:
24072 /// - `user_guid`: The unique identifier for a `user`, beginning with the
24073 /// prefix `USR-`.
24074 /// - `member_guid`: The unique id for a `member`.
24075 /// - `body`: Member object with MFA challenge answers
24076 pub async fn resume_aggregation<'a>(
24077 &'a self,
24078 user_guid: &'a str,
24079 member_guid: &'a str,
24080 body: &'a types::MemberResumeRequestBody,
24081 ) -> Result<ResponseValue<types::MemberResponseBody>, Error<()>> {
24082 let url = format!(
24083 "{}/users/{}/members/{}/resume",
24084 self.baseurl,
24085 encode_path(&user_guid.to_string()),
24086 encode_path(&member_guid.to_string()),
24087 );
24088 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
24089 header_map.append(
24090 ::reqwest::header::HeaderName::from_static("api-version"),
24091 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
24092 );
24093 #[allow(unused_mut)]
24094 let mut request = self
24095 .client
24096 .put(url)
24097 .header(
24098 ::reqwest::header::ACCEPT,
24099 ::reqwest::header::HeaderValue::from_static("application/json"),
24100 )
24101 .json(&body)
24102 .headers(header_map)
24103 .build()?;
24104 let info = OperationInfo {
24105 operation_id: "resume_aggregation",
24106 };
24107 self.pre(&mut request, &info).await?;
24108 let result = self.exec(request, &info).await;
24109 self.post(&result, &info).await?;
24110 let response = result?;
24111 match response.status().as_u16() {
24112 202u16 => ResponseValue::from_response(response).await,
24113 _ => Err(Error::UnexpectedResponse(response)),
24114 }
24115 }
24116
24117 ///List statements by member
24118 ///
24119 ///Use this endpoint to get an array of available statements.
24120 ///
24121 ///Sends a `GET` request to
24122 /// `/users/{user_guid}/members/{member_guid}/statements`
24123 ///
24124 ///Arguments:
24125 /// - `user_guid`: The unique identifier for a `user`, beginning with the
24126 /// prefix `USR-`.
24127 /// - `member_guid`: The unique id for a `member`.
24128 /// - `page`: Results are paginated. Specify current page.
24129 /// - `records_per_page`: This specifies the number of records to be
24130 /// returned on each page. Defaults to `25`. The valid range is from `10`
24131 /// to `1000`. If the value exceeds `1000`, the default value of `25` will
24132 /// be used instead.
24133 pub async fn list_statements_by_member<'a>(
24134 &'a self,
24135 user_guid: &'a str,
24136 member_guid: &'a str,
24137 page: Option<i64>,
24138 records_per_page: Option<i64>,
24139 ) -> Result<ResponseValue<types::StatementsResponseBody>, Error<()>> {
24140 let url = format!(
24141 "{}/users/{}/members/{}/statements",
24142 self.baseurl,
24143 encode_path(&user_guid.to_string()),
24144 encode_path(&member_guid.to_string()),
24145 );
24146 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
24147 header_map.append(
24148 ::reqwest::header::HeaderName::from_static("api-version"),
24149 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
24150 );
24151 #[allow(unused_mut)]
24152 let mut request = self
24153 .client
24154 .get(url)
24155 .header(
24156 ::reqwest::header::ACCEPT,
24157 ::reqwest::header::HeaderValue::from_static("application/json"),
24158 )
24159 .query(&progenitor_client::QueryParam::new("page", &page))
24160 .query(&progenitor_client::QueryParam::new(
24161 "records_per_page",
24162 &records_per_page,
24163 ))
24164 .headers(header_map)
24165 .build()?;
24166 let info = OperationInfo {
24167 operation_id: "list_statements_by_member",
24168 };
24169 self.pre(&mut request, &info).await?;
24170 let result = self.exec(request, &info).await;
24171 self.post(&result, &info).await?;
24172 let response = result?;
24173 match response.status().as_u16() {
24174 200u16 => ResponseValue::from_response(response).await,
24175 _ => Err(Error::UnexpectedResponse(response)),
24176 }
24177 }
24178
24179 ///Read statement by member
24180 ///
24181 ///Use this endpoint to read a JSON representation of the statement.
24182 ///
24183 ///Sends a `GET` request to
24184 /// `/users/{user_guid}/members/{member_guid}/statements/{statement_guid}`
24185 ///
24186 ///Arguments:
24187 /// - `user_guid`: The unique identifier for a `user`, beginning with the
24188 /// prefix `USR-`.
24189 /// - `member_guid`: The unique id for a `member`.
24190 /// - `statement_guid`: The unique id for a `statement`.
24191 pub async fn read_statement_by_member<'a>(
24192 &'a self,
24193 user_guid: &'a str,
24194 member_guid: &'a str,
24195 statement_guid: &'a str,
24196 ) -> Result<ResponseValue<types::StatementResponseBody>, Error<()>> {
24197 let url = format!(
24198 "{}/users/{}/members/{}/statements/{}",
24199 self.baseurl,
24200 encode_path(&user_guid.to_string()),
24201 encode_path(&member_guid.to_string()),
24202 encode_path(&statement_guid.to_string()),
24203 );
24204 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
24205 header_map.append(
24206 ::reqwest::header::HeaderName::from_static("api-version"),
24207 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
24208 );
24209 #[allow(unused_mut)]
24210 let mut request = self
24211 .client
24212 .get(url)
24213 .header(
24214 ::reqwest::header::ACCEPT,
24215 ::reqwest::header::HeaderValue::from_static("application/json"),
24216 )
24217 .headers(header_map)
24218 .build()?;
24219 let info = OperationInfo {
24220 operation_id: "read_statement_by_member",
24221 };
24222 self.pre(&mut request, &info).await?;
24223 let result = self.exec(request, &info).await;
24224 self.post(&result, &info).await?;
24225 let response = result?;
24226 match response.status().as_u16() {
24227 200u16 => ResponseValue::from_response(response).await,
24228 _ => Err(Error::UnexpectedResponse(response)),
24229 }
24230 }
24231
24232 ///Download statement pdf
24233 ///
24234 ///Use this endpoint to download a specified statement PDF.
24235 ///
24236 ///Sends a `GET` request to
24237 /// `/users/{user_guid}/members/{member_guid}/statements/{statement_guid}.
24238 /// pdf`
24239 ///
24240 ///Arguments:
24241 /// - `user_guid`: The unique identifier for a `user`, beginning with the
24242 /// prefix `USR-`.
24243 /// - `member_guid`: The unique id for a `member`.
24244 /// - `statement_guid`: The unique id for a `statement`.
24245 pub async fn download_statement_pdf<'a>(
24246 &'a self,
24247 user_guid: &'a str,
24248 member_guid: &'a str,
24249 statement_guid: &'a str,
24250 ) -> Result<ResponseValue<ByteStream>, Error<()>> {
24251 let url = format!(
24252 "{}/users/{}/members/{}/statements/{}.pdf",
24253 self.baseurl,
24254 encode_path(&user_guid.to_string()),
24255 encode_path(&member_guid.to_string()),
24256 encode_path(&statement_guid.to_string()),
24257 );
24258 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
24259 header_map.append(
24260 ::reqwest::header::HeaderName::from_static("api-version"),
24261 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
24262 );
24263 #[allow(unused_mut)]
24264 let mut request = self.client.get(url).headers(header_map).build()?;
24265 let info = OperationInfo {
24266 operation_id: "download_statement_pdf",
24267 };
24268 self.pre(&mut request, &info).await?;
24269 let result = self.exec(request, &info).await;
24270 self.post(&result, &info).await?;
24271 let response = result?;
24272 match response.status().as_u16() {
24273 200u16 => Ok(ResponseValue::stream(response)),
24274 _ => Err(Error::UnexpectedResponse(response)),
24275 }
24276 }
24277
24278 ///Read member status
24279 ///
24280 ///This endpoint provides the status of the members most recent aggregation
24281 /// event. This is an important step in the aggregation process, and the
24282 /// results returned by this endpoint should determine what you do next in
24283 /// order to successfully aggregate a member. MX has introduced new, more
24284 /// detailed information on the current status of a members connection to a
24285 /// financial institution and the state of its aggregation - the
24286 /// connection_status field. These are intended to replace and expand upon
24287 /// the information provided in the status field, which will soon be
24288 /// deprecated; support for the status field remains for the time being.
24289 ///
24290 ///Sends a `GET` request to
24291 /// `/users/{user_guid}/members/{member_guid}/status`
24292 ///
24293 ///Arguments:
24294 /// - `user_guid`: The unique identifier for a `user`, beginning with the
24295 /// prefix `USR-`.
24296 /// - `member_guid`: The unique id for a `member`.
24297 pub async fn read_member_status<'a>(
24298 &'a self,
24299 user_guid: &'a str,
24300 member_guid: &'a str,
24301 ) -> Result<ResponseValue<types::MemberStatusResponseBody>, Error<()>> {
24302 let url = format!(
24303 "{}/users/{}/members/{}/status",
24304 self.baseurl,
24305 encode_path(&user_guid.to_string()),
24306 encode_path(&member_guid.to_string()),
24307 );
24308 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
24309 header_map.append(
24310 ::reqwest::header::HeaderName::from_static("api-version"),
24311 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
24312 );
24313 #[allow(unused_mut)]
24314 let mut request = self
24315 .client
24316 .get(url)
24317 .header(
24318 ::reqwest::header::ACCEPT,
24319 ::reqwest::header::HeaderValue::from_static("application/json"),
24320 )
24321 .headers(header_map)
24322 .build()?;
24323 let info = OperationInfo {
24324 operation_id: "read_member_status",
24325 };
24326 self.pre(&mut request, &info).await?;
24327 let result = self.exec(request, &info).await;
24328 self.post(&result, &info).await?;
24329 let response = result?;
24330 match response.status().as_u16() {
24331 200u16 => ResponseValue::from_response(response).await,
24332 _ => Err(Error::UnexpectedResponse(response)),
24333 }
24334 }
24335
24336 ///List transactions by member
24337 ///
24338 ///Requests to this endpoint return a list of transactions associated with
24339 /// the specified `member`, across all accounts associated with that
24340 /// `member`. <br /><br />Enhanced transaction data may be requested using
24341 /// the `includes` parameter. To use this optional parameter, the value
24342 /// should include the optional metadata requested such as
24343 /// `repeating_transactions`, `merchants`, `classifications`,
24344 /// `geolocations`. For more information, see the [Optional Enhancement
24345 /// Query Parameter
24346 /// guide](/api-reference/platform-api/reference/transactions-overview#
24347 /// enhanced-transactions#optional-enhancement-query-parameter).
24348 ///
24349 ///Sends a `GET` request to
24350 /// `/users/{user_guid}/members/{member_guid}/transactions`
24351 ///
24352 ///Arguments:
24353 /// - `user_guid`: The unique identifier for a `user`, beginning with the
24354 /// prefix `USR-`.
24355 /// - `member_guid`: The unique id for a `member`.
24356 /// - `category_guid`: Filter transactions belonging to specified
24357 /// `category_guid`.
24358 ///
24359 ///For example, `?category_guid=CAT-7829f71c-2e8c-afa5-2f55-fa3634b89874`.
24360 /// - `category_guid`: Filter transactions belonging to any specified
24361 /// `category_guid[]` in url.
24362 ///
24363 ///For example,
24364 /// `?category_guid[]=CAT-7829f71c-2e8c-afa5-2f55-fa3634b89874`.
24365 /// - `from_created_at`: Filter transactions from the date the transaction
24366 /// was created. This only supports ISO 8601 format without timestamp
24367 /// (YYYY-MM-DD). Maximum date range limit is 6 months.
24368 /// - `from_date`: Filter transactions from this date. This only supports
24369 /// ISO 8601 format without timestamp (YYYY-MM-DD). Defaults to 120 days
24370 /// ago if not provided.
24371 /// - `from_updated_at`: Filter transactions from the date in which the
24372 /// transaction was updated. This only supports ISO 8601 format without
24373 /// timestamp (YYYY-MM-DD). Maximum date range limit is 6 months.
24374 /// - `includes`: Options for enhanced transactions. This query parameter is
24375 /// optional. Possible additional metadata: `repeating_transactions`,
24376 /// `merchants`, `classifications`, `geolocations`. The query value is
24377 /// format sensitive. To retrieve all available enhancements, append:
24378 ///
24379 ///`?includes=repeating_transactions,merchants,classifications,
24380 /// geolocations`.
24381 ///
24382 ///The query options may be combined to specific enhancements. For example,
24383 /// to request Repeating Transactions and Geolocation data, use:
24384 ///
24385 ///`?includes=repeating_transactions,geolocations`.
24386 ///
24387 /// - Repeating Transactions: Identifies transactions with predictable
24388 /// recurrence patterns (e.g., Bill, Income, Subscription).
24389 /// - Merchants: Enriches transactions with merchant name.
24390 /// - Classifications: Provides more insight into the type of money movement
24391 /// that is occurring on the transaction, whether it be retail or
24392 /// investments.
24393 /// - Geolocation: Provides geographic metadata.
24394 ///
24395 /// - `page`: Results are paginated. Specify current page.
24396 /// - `records_per_page`: This specifies the number of records to be
24397 /// returned on each page. Defaults to `25`. The valid range is from `10`
24398 /// to `1000`. If the value exceeds `1000`, the default value of `25` will
24399 /// be used instead.
24400 /// - `to_created_at`: Filter transaction to the date in which the
24401 /// transaction was created. This only supports ISO 8601 format without
24402 /// timestamp (YYYY-MM-DD). Maximum date range limit is 6 months.
24403 /// - `to_date`: Filter transactions to this date (at midnight). This only
24404 /// supports ISO 8601 format without timestamp (YYYY-MM-DD). Defaults to 5
24405 /// days forward from the day the request is made to capture pending
24406 /// transactions.
24407 /// - `to_updated_at`: Filter transactions to the date in which the
24408 /// transaction was updated. This only supports ISO 8601 format without
24409 /// timestamp (YYYY-MM-DD). Maximum date range limit is 6 months.
24410 /// - `top_level_category_guid`: Filter transactions belonging to specified
24411 /// `top_level_category_guid`. This must be top level category guid, use
24412 /// `category_guid` for subcategory guid.
24413 ///
24414 ///For example,
24415 /// `?top_level_category_guid=CAT-7829f71c-2e8c-afa5-2f55-fa3634b89874`.
24416 /// - `top_level_category_guid`: Filter transactions belonging to any
24417 /// specified `top_level_category_guid[]` in url. This must be top level
24418 /// category guid(s), use `category_guid` for subcategory guid(s).
24419 ///
24420 ///For example,
24421 /// `?top_level_category_guid[]=CAT-7829f71c-2e8c-afa5-2f55-fa3634b89874`.
24422 pub async fn list_transactions_by_member<'a>(
24423 &'a self,
24424 user_guid: &'a str,
24425 member_guid: &'a str,
24426 category_guid: Option<&'a str>,
24427 from_created_at: Option<&'a str>,
24428 from_date: Option<&'a str>,
24429 from_updated_at: Option<&'a str>,
24430 includes: Option<&'a str>,
24431 page: Option<i64>,
24432 records_per_page: Option<i64>,
24433 to_created_at: Option<&'a str>,
24434 to_date: Option<&'a str>,
24435 to_updated_at: Option<&'a str>,
24436 top_level_category_guid: Option<&'a str>,
24437 ) -> Result<ResponseValue<types::TransactionsResponseBodyIncludes>, Error<()>> {
24438 let url = format!(
24439 "{}/users/{}/members/{}/transactions",
24440 self.baseurl,
24441 encode_path(&user_guid.to_string()),
24442 encode_path(&member_guid.to_string()),
24443 );
24444 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
24445 header_map.append(
24446 ::reqwest::header::HeaderName::from_static("api-version"),
24447 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
24448 );
24449 #[allow(unused_mut)]
24450 let mut request = self
24451 .client
24452 .get(url)
24453 .header(
24454 ::reqwest::header::ACCEPT,
24455 ::reqwest::header::HeaderValue::from_static("application/json"),
24456 )
24457 .query(&progenitor_client::QueryParam::new(
24458 "category_guid",
24459 &category_guid,
24460 ))
24461 .query(&progenitor_client::QueryParam::new(
24462 "category_guid[]",
24463 &category_guid,
24464 ))
24465 .query(&progenitor_client::QueryParam::new(
24466 "from_created_at",
24467 &from_created_at,
24468 ))
24469 .query(&progenitor_client::QueryParam::new("from_date", &from_date))
24470 .query(&progenitor_client::QueryParam::new(
24471 "from_updated_at",
24472 &from_updated_at,
24473 ))
24474 .query(&progenitor_client::QueryParam::new("includes", &includes))
24475 .query(&progenitor_client::QueryParam::new("page", &page))
24476 .query(&progenitor_client::QueryParam::new(
24477 "records_per_page",
24478 &records_per_page,
24479 ))
24480 .query(&progenitor_client::QueryParam::new(
24481 "to_created_at",
24482 &to_created_at,
24483 ))
24484 .query(&progenitor_client::QueryParam::new("to_date", &to_date))
24485 .query(&progenitor_client::QueryParam::new(
24486 "to_updated_at",
24487 &to_updated_at,
24488 ))
24489 .query(&progenitor_client::QueryParam::new(
24490 "top_level_category_guid",
24491 &top_level_category_guid,
24492 ))
24493 .query(&progenitor_client::QueryParam::new(
24494 "top_level_category_guid[]",
24495 &top_level_category_guid,
24496 ))
24497 .headers(header_map)
24498 .build()?;
24499 let info = OperationInfo {
24500 operation_id: "list_transactions_by_member",
24501 };
24502 self.pre(&mut request, &info).await?;
24503 let result = self.exec(request, &info).await;
24504 self.post(&result, &info).await?;
24505 let response = result?;
24506 match response.status().as_u16() {
24507 200u16 => ResponseValue::from_response(response).await,
24508 _ => Err(Error::UnexpectedResponse(response)),
24509 }
24510 }
24511
24512 ///Verify member
24513 ///
24514 ///The verify endpoint begins a verification process for a member.
24515 ///
24516 ///Sends a `POST` request to
24517 /// `/users/{user_guid}/members/{member_guid}/verify`
24518 ///
24519 ///Arguments:
24520 /// - `user_guid`: The unique identifier for a `user`, beginning with the
24521 /// prefix `USR-`.
24522 /// - `member_guid`: The unique id for a `member`.
24523 /// - `x_callback_payload`: The base64 encoded string defined in this header
24524 /// will be returned in the [Member](/resources/webhooks/member/) and
24525 /// [Member Data Updated](/resources/webhooks/member#member-data-updated)
24526 /// webhooks. This allows you to trace user interactions and workflows
24527 /// initiated externally and internally in the MX Platform. Max 1024
24528 /// characters.
24529 pub async fn verify_member<'a>(
24530 &'a self,
24531 user_guid: &'a str,
24532 member_guid: &'a str,
24533 x_callback_payload: Option<&'a str>,
24534 ) -> Result<ResponseValue<types::MemberResponseBody>, Error<()>> {
24535 let url = format!(
24536 "{}/users/{}/members/{}/verify",
24537 self.baseurl,
24538 encode_path(&user_guid.to_string()),
24539 encode_path(&member_guid.to_string()),
24540 );
24541 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(2usize);
24542 header_map.append(
24543 ::reqwest::header::HeaderName::from_static("api-version"),
24544 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
24545 );
24546 if let Some(value) = x_callback_payload {
24547 header_map.append("X-CALLBACK-PAYLOAD", value.to_string().try_into()?);
24548 }
24549
24550 #[allow(unused_mut)]
24551 let mut request = self
24552 .client
24553 .post(url)
24554 .header(
24555 ::reqwest::header::ACCEPT,
24556 ::reqwest::header::HeaderValue::from_static("application/json"),
24557 )
24558 .headers(header_map)
24559 .build()?;
24560 let info = OperationInfo {
24561 operation_id: "verify_member",
24562 };
24563 self.pre(&mut request, &info).await?;
24564 let result = self.exec(request, &info).await;
24565 self.post(&result, &info).await?;
24566 let response = result?;
24567 match response.status().as_u16() {
24568 200u16 => ResponseValue::from_response(response).await,
24569 _ => Err(Error::UnexpectedResponse(response)),
24570 }
24571 }
24572
24573 ///List spending plan iteration items
24574 ///
24575 ///Use this endpoint to list all the spending plan `iteration_items`
24576 /// associated with the `iteration`.
24577 ///
24578 ///Sends a `GET` request to
24579 /// `/users/{user_guid}/spending_plans/{spending_plan_guid}/iterations/
24580 /// current/iteration_items`
24581 ///
24582 ///Arguments:
24583 /// - `user_guid`: The unique identifier for a `user`, beginning with the
24584 /// prefix `USR-`.
24585 /// - `spending_plan_guid`: The unique ID for the `spending_plan`.
24586 /// - `page`: Results are paginated. Specify current page.
24587 /// - `records_per_page`: This specifies the number of records to be
24588 /// returned on each page. Defaults to `25`. The valid range is from `10`
24589 /// to `1000`. If the value exceeds `1000`, the default value of `25` will
24590 /// be used instead.
24591 pub async fn list_spending_plan_iteration_items<'a>(
24592 &'a self,
24593 user_guid: &'a str,
24594 spending_plan_guid: &'a str,
24595 page: Option<i64>,
24596 records_per_page: Option<i64>,
24597 ) -> Result<ResponseValue<types::SpendingPlanIterationItemsResponseBody>, Error<()>> {
24598 let url = format!(
24599 "{}/users/{}/spending_plans/{}/iterations/current/iteration_items",
24600 self.baseurl,
24601 encode_path(&user_guid.to_string()),
24602 encode_path(&spending_plan_guid.to_string()),
24603 );
24604 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
24605 header_map.append(
24606 ::reqwest::header::HeaderName::from_static("api-version"),
24607 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
24608 );
24609 #[allow(unused_mut)]
24610 let mut request = self
24611 .client
24612 .get(url)
24613 .header(
24614 ::reqwest::header::ACCEPT,
24615 ::reqwest::header::HeaderValue::from_static("application/json"),
24616 )
24617 .query(&progenitor_client::QueryParam::new("page", &page))
24618 .query(&progenitor_client::QueryParam::new(
24619 "records_per_page",
24620 &records_per_page,
24621 ))
24622 .headers(header_map)
24623 .build()?;
24624 let info = OperationInfo {
24625 operation_id: "list_spending_plan_iteration_items",
24626 };
24627 self.pre(&mut request, &info).await?;
24628 let result = self.exec(request, &info).await;
24629 self.post(&result, &info).await?;
24630 let response = result?;
24631 match response.status().as_u16() {
24632 200u16 => ResponseValue::from_response(response).await,
24633 _ => Err(Error::UnexpectedResponse(response)),
24634 }
24635 }
24636
24637 ///Create spending plan iteration item
24638 ///
24639 ///This endpoint creates a new `spending_plan_iteration_item`.
24640 ///
24641 ///Sends a `POST` request to
24642 /// `/users/{user_guid}/spending_plans/{spending_plan_guid}/iterations/
24643 /// current/iteration_items`
24644 ///
24645 ///Arguments:
24646 /// - `user_guid`: The unique identifier for a `user`, beginning with the
24647 /// prefix `USR-`.
24648 /// - `spending_plan_guid`: The unique ID for the `spending_plan`.
24649 /// - `body`: Iteration item to be created with required parameter
24650 /// (planned_amount)
24651 pub async fn create_spending_plan_iteration_item<'a>(
24652 &'a self,
24653 user_guid: &'a str,
24654 spending_plan_guid: &'a str,
24655 body: &'a types::SpendingPlanIterationItemCreateRequestBody,
24656 ) -> Result<ResponseValue<types::SpendingPlanIterationItemResponse>, Error<()>> {
24657 let url = format!(
24658 "{}/users/{}/spending_plans/{}/iterations/current/iteration_items",
24659 self.baseurl,
24660 encode_path(&user_guid.to_string()),
24661 encode_path(&spending_plan_guid.to_string()),
24662 );
24663 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
24664 header_map.append(
24665 ::reqwest::header::HeaderName::from_static("api-version"),
24666 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
24667 );
24668 #[allow(unused_mut)]
24669 let mut request = self
24670 .client
24671 .post(url)
24672 .header(
24673 ::reqwest::header::ACCEPT,
24674 ::reqwest::header::HeaderValue::from_static("application/json"),
24675 )
24676 .json(&body)
24677 .headers(header_map)
24678 .build()?;
24679 let info = OperationInfo {
24680 operation_id: "create_spending_plan_iteration_item",
24681 };
24682 self.pre(&mut request, &info).await?;
24683 let result = self.exec(request, &info).await;
24684 self.post(&result, &info).await?;
24685 let response = result?;
24686 match response.status().as_u16() {
24687 200u16 => ResponseValue::from_response(response).await,
24688 _ => Err(Error::UnexpectedResponse(response)),
24689 }
24690 }
24691
24692 ///List spending plans
24693 ///
24694 ///Use this endpoint to list all the spending plans associated with the
24695 /// user.
24696 ///
24697 ///Sends a `GET` request to `/users/{user_guid}/spending_plans`
24698 ///
24699 ///Arguments:
24700 /// - `user_guid`: The unique identifier for a `user`, beginning with the
24701 /// prefix `USR-`.
24702 /// - `page`: Results are paginated. Specify current page.
24703 /// - `records_per_page`: This specifies the number of records to be
24704 /// returned on each page. Defaults to `25`. The valid range is from `10`
24705 /// to `1000`. If the value exceeds `1000`, the default value of `25` will
24706 /// be used instead.
24707 pub async fn list_spending_plans<'a>(
24708 &'a self,
24709 user_guid: &'a str,
24710 page: Option<i64>,
24711 records_per_page: Option<i64>,
24712 ) -> Result<ResponseValue<types::SpendingPlansResponseBody>, Error<()>> {
24713 let url = format!(
24714 "{}/users/{}/spending_plans",
24715 self.baseurl,
24716 encode_path(&user_guid.to_string()),
24717 );
24718 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
24719 header_map.append(
24720 ::reqwest::header::HeaderName::from_static("api-version"),
24721 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
24722 );
24723 #[allow(unused_mut)]
24724 let mut request = self
24725 .client
24726 .get(url)
24727 .header(
24728 ::reqwest::header::ACCEPT,
24729 ::reqwest::header::HeaderValue::from_static("application/json"),
24730 )
24731 .query(&progenitor_client::QueryParam::new("page", &page))
24732 .query(&progenitor_client::QueryParam::new(
24733 "records_per_page",
24734 &records_per_page,
24735 ))
24736 .headers(header_map)
24737 .build()?;
24738 let info = OperationInfo {
24739 operation_id: "list_spending_plans",
24740 };
24741 self.pre(&mut request, &info).await?;
24742 let result = self.exec(request, &info).await;
24743 self.post(&result, &info).await?;
24744 let response = result?;
24745 match response.status().as_u16() {
24746 200u16 => ResponseValue::from_response(response).await,
24747 _ => Err(Error::UnexpectedResponse(response)),
24748 }
24749 }
24750
24751 ///Create spending plan
24752 ///
24753 ///This endpoint creates a new `spending_plan` for the user.
24754 ///
24755 ///Sends a `POST` request to `/users/{user_guid}/spending_plans`
24756 ///
24757 ///Arguments:
24758 /// - `user_guid`: The unique identifier for a `user`, beginning with the
24759 /// prefix `USR-`.
24760 pub async fn create_spending_plan<'a>(
24761 &'a self,
24762 user_guid: &'a str,
24763 ) -> Result<ResponseValue<types::SpendingPlanResponse>, Error<()>> {
24764 let url = format!(
24765 "{}/users/{}/spending_plans",
24766 self.baseurl,
24767 encode_path(&user_guid.to_string()),
24768 );
24769 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
24770 header_map.append(
24771 ::reqwest::header::HeaderName::from_static("api-version"),
24772 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
24773 );
24774 #[allow(unused_mut)]
24775 let mut request = self
24776 .client
24777 .post(url)
24778 .header(
24779 ::reqwest::header::ACCEPT,
24780 ::reqwest::header::HeaderValue::from_static("application/json"),
24781 )
24782 .headers(header_map)
24783 .build()?;
24784 let info = OperationInfo {
24785 operation_id: "create_spending_plan",
24786 };
24787 self.pre(&mut request, &info).await?;
24788 let result = self.exec(request, &info).await;
24789 self.post(&result, &info).await?;
24790 let response = result?;
24791 match response.status().as_u16() {
24792 200u16 => ResponseValue::from_response(response).await,
24793 _ => Err(Error::UnexpectedResponse(response)),
24794 }
24795 }
24796
24797 ///Read spending plan account
24798 ///
24799 ///Use this endpoint to read the attributes of a specific spending plan
24800 /// account according to its unique GUID.
24801 ///
24802 ///Sends a `GET` request to
24803 /// `/users/{user_guid}/spending_plans/{spending_plan_guid}/
24804 /// spending_plan_accounts/{spending_plan_account_guid}`
24805 ///
24806 ///Arguments:
24807 /// - `user_guid`: The unique identifier for a `user`, beginning with the
24808 /// prefix `USR-`.
24809 /// - `spending_plan_guid`: The unique ID for the `spending_plan`.
24810 /// - `spending_plan_account_guid`: The unique ID for the specified account.
24811 /// - `page`: Results are paginated. Specify current page.
24812 /// - `records_per_page`: This specifies the number of records to be
24813 /// returned on each page. Defaults to `25`. The valid range is from `10`
24814 /// to `1000`. If the value exceeds `1000`, the default value of `25` will
24815 /// be used instead.
24816 pub async fn read_spending_plan_account<'a>(
24817 &'a self,
24818 user_guid: &'a str,
24819 spending_plan_guid: &'a str,
24820 spending_plan_account_guid: &'a str,
24821 page: Option<i64>,
24822 records_per_page: Option<i64>,
24823 ) -> Result<ResponseValue<types::SpendingPlanAccountResponse>, Error<()>> {
24824 let url = format!(
24825 "{}/users/{}/spending_plans/{}/spending_plan_accounts/{}",
24826 self.baseurl,
24827 encode_path(&user_guid.to_string()),
24828 encode_path(&spending_plan_guid.to_string()),
24829 encode_path(&spending_plan_account_guid.to_string()),
24830 );
24831 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
24832 header_map.append(
24833 ::reqwest::header::HeaderName::from_static("api-version"),
24834 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
24835 );
24836 #[allow(unused_mut)]
24837 let mut request = self
24838 .client
24839 .get(url)
24840 .header(
24841 ::reqwest::header::ACCEPT,
24842 ::reqwest::header::HeaderValue::from_static("application/json"),
24843 )
24844 .query(&progenitor_client::QueryParam::new("page", &page))
24845 .query(&progenitor_client::QueryParam::new(
24846 "records_per_page",
24847 &records_per_page,
24848 ))
24849 .headers(header_map)
24850 .build()?;
24851 let info = OperationInfo {
24852 operation_id: "read_spending_plan_account",
24853 };
24854 self.pre(&mut request, &info).await?;
24855 let result = self.exec(request, &info).await;
24856 self.post(&result, &info).await?;
24857 let response = result?;
24858 match response.status().as_u16() {
24859 200u16 => ResponseValue::from_response(response).await,
24860 _ => Err(Error::UnexpectedResponse(response)),
24861 }
24862 }
24863
24864 ///Delete spending plan account
24865 ///
24866 ///Use this endpoint to delete a `spending_plan_account`.
24867 ///
24868 ///Sends a `DELETE` request to
24869 /// `/users/{user_guid}/spending_plans/{spending_plan_guid}/
24870 /// spending_plan_accounts/{spending_plan_account_guid}`
24871 ///
24872 ///Arguments:
24873 /// - `user_guid`: The unique identifier for a `user`, beginning with the
24874 /// prefix `USR-`.
24875 /// - `spending_plan_guid`: The unique ID for the `spending_plan`.
24876 /// - `spending_plan_account_guid`: The unique ID for the specified account.
24877 pub async fn delete_spending_plan_account<'a>(
24878 &'a self,
24879 user_guid: &'a str,
24880 spending_plan_guid: &'a str,
24881 spending_plan_account_guid: &'a str,
24882 ) -> Result<ResponseValue<()>, Error<()>> {
24883 let url = format!(
24884 "{}/users/{}/spending_plans/{}/spending_plan_accounts/{}",
24885 self.baseurl,
24886 encode_path(&user_guid.to_string()),
24887 encode_path(&spending_plan_guid.to_string()),
24888 encode_path(&spending_plan_account_guid.to_string()),
24889 );
24890 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
24891 header_map.append(
24892 ::reqwest::header::HeaderName::from_static("api-version"),
24893 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
24894 );
24895 #[allow(unused_mut)]
24896 let mut request = self.client.delete(url).headers(header_map).build()?;
24897 let info = OperationInfo {
24898 operation_id: "delete_spending_plan_account",
24899 };
24900 self.pre(&mut request, &info).await?;
24901 let result = self.exec(request, &info).await;
24902 self.post(&result, &info).await?;
24903 let response = result?;
24904 match response.status().as_u16() {
24905 204u16 => Ok(ResponseValue::empty(response)),
24906 _ => Err(Error::UnexpectedResponse(response)),
24907 }
24908 }
24909
24910 ///Read a spending plan iteration item
24911 ///
24912 ///Use this endpoint to read the attributes of a specific spending plan
24913 /// `iteration_item` according to its unique GUID.
24914 ///
24915 ///Sends a `GET` request to
24916 /// `/users/{user_guid}/spending_plans/{spending_plan_guid}/iterations/
24917 /// current/iteration_items/{iteration_item_guid}`
24918 ///
24919 ///Arguments:
24920 /// - `user_guid`: The unique identifier for a `user`, beginning with the
24921 /// prefix `USR-`.
24922 /// - `spending_plan_guid`: The unique ID for the `spending_plan`.
24923 /// - `iteration_item_guid`: The unique ID for the `iteration_item`.
24924 /// - `page`: Results are paginated. Specify current page.
24925 /// - `records_per_page`: This specifies the number of records to be
24926 /// returned on each page. Defaults to `25`. The valid range is from `10`
24927 /// to `1000`. If the value exceeds `1000`, the default value of `25` will
24928 /// be used instead.
24929 pub async fn read_spending_plan_iteration_item<'a>(
24930 &'a self,
24931 user_guid: &'a str,
24932 spending_plan_guid: &'a str,
24933 iteration_item_guid: &'a str,
24934 page: Option<i64>,
24935 records_per_page: Option<i64>,
24936 ) -> Result<ResponseValue<types::SpendingPlanIterationItemResponse>, Error<()>> {
24937 let url = format!(
24938 "{}/users/{}/spending_plans/{}/iterations/current/iteration_items/{}",
24939 self.baseurl,
24940 encode_path(&user_guid.to_string()),
24941 encode_path(&spending_plan_guid.to_string()),
24942 encode_path(&iteration_item_guid.to_string()),
24943 );
24944 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
24945 header_map.append(
24946 ::reqwest::header::HeaderName::from_static("api-version"),
24947 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
24948 );
24949 #[allow(unused_mut)]
24950 let mut request = self
24951 .client
24952 .get(url)
24953 .header(
24954 ::reqwest::header::ACCEPT,
24955 ::reqwest::header::HeaderValue::from_static("application/json"),
24956 )
24957 .query(&progenitor_client::QueryParam::new("page", &page))
24958 .query(&progenitor_client::QueryParam::new(
24959 "records_per_page",
24960 &records_per_page,
24961 ))
24962 .headers(header_map)
24963 .build()?;
24964 let info = OperationInfo {
24965 operation_id: "read_spending_plan_iteration_item",
24966 };
24967 self.pre(&mut request, &info).await?;
24968 let result = self.exec(request, &info).await;
24969 self.post(&result, &info).await?;
24970 let response = result?;
24971 match response.status().as_u16() {
24972 200u16 => ResponseValue::from_response(response).await,
24973 _ => Err(Error::UnexpectedResponse(response)),
24974 }
24975 }
24976
24977 ///Update a spending plan iteration item
24978 ///
24979 ///Use this endpoint to update an existing `spending_plan_iteration_item`.
24980 ///
24981 ///Sends a `PUT` request to
24982 /// `/users/{user_guid}/spending_plans/{spending_plan_guid}/iterations/
24983 /// current/iteration_items/{iteration_item_guid}`
24984 ///
24985 ///Arguments:
24986 /// - `user_guid`: The unique identifier for a `user`, beginning with the
24987 /// prefix `USR-`.
24988 /// - `spending_plan_guid`: The unique ID for the `spending_plan`.
24989 /// - `iteration_item_guid`: The unique ID for the `iteration_item`.
24990 /// - `body`: Iteration item to be updated with required parameter
24991 /// (planned_amount)
24992 pub async fn update_spending_plan_iteration_item<'a>(
24993 &'a self,
24994 user_guid: &'a str,
24995 spending_plan_guid: &'a str,
24996 iteration_item_guid: &'a str,
24997 body: &'a types::SpendingPlanIterationItemCreateRequestBody,
24998 ) -> Result<ResponseValue<types::SpendingPlanIterationItemResponse>, Error<()>> {
24999 let url = format!(
25000 "{}/users/{}/spending_plans/{}/iterations/current/iteration_items/{}",
25001 self.baseurl,
25002 encode_path(&user_guid.to_string()),
25003 encode_path(&spending_plan_guid.to_string()),
25004 encode_path(&iteration_item_guid.to_string()),
25005 );
25006 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
25007 header_map.append(
25008 ::reqwest::header::HeaderName::from_static("api-version"),
25009 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
25010 );
25011 #[allow(unused_mut)]
25012 let mut request = self
25013 .client
25014 .put(url)
25015 .header(
25016 ::reqwest::header::ACCEPT,
25017 ::reqwest::header::HeaderValue::from_static("application/json"),
25018 )
25019 .json(&body)
25020 .headers(header_map)
25021 .build()?;
25022 let info = OperationInfo {
25023 operation_id: "update_spending_plan_iteration_item",
25024 };
25025 self.pre(&mut request, &info).await?;
25026 let result = self.exec(request, &info).await;
25027 self.post(&result, &info).await?;
25028 let response = result?;
25029 match response.status().as_u16() {
25030 200u16 => ResponseValue::from_response(response).await,
25031 _ => Err(Error::UnexpectedResponse(response)),
25032 }
25033 }
25034
25035 ///Delete spending plan iteration item
25036 ///
25037 ///Use this endpoint to delete a spending plan `iteration_item`.
25038 ///
25039 ///Sends a `DELETE` request to
25040 /// `/users/{user_guid}/spending_plans/{spending_plan_guid}/iterations/
25041 /// current/iteration_items/{iteration_item_guid}`
25042 ///
25043 ///Arguments:
25044 /// - `user_guid`: The unique identifier for a `user`, beginning with the
25045 /// prefix `USR-`.
25046 /// - `spending_plan_guid`: The unique ID for the `spending_plan`.
25047 /// - `iteration_item_guid`: The unique ID for the `iteration_item`.
25048 pub async fn delete_spending_plan_iteration_item<'a>(
25049 &'a self,
25050 user_guid: &'a str,
25051 spending_plan_guid: &'a str,
25052 iteration_item_guid: &'a str,
25053 ) -> Result<ResponseValue<()>, Error<()>> {
25054 let url = format!(
25055 "{}/users/{}/spending_plans/{}/iterations/current/iteration_items/{}",
25056 self.baseurl,
25057 encode_path(&user_guid.to_string()),
25058 encode_path(&spending_plan_guid.to_string()),
25059 encode_path(&iteration_item_guid.to_string()),
25060 );
25061 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
25062 header_map.append(
25063 ::reqwest::header::HeaderName::from_static("api-version"),
25064 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
25065 );
25066 #[allow(unused_mut)]
25067 let mut request = self.client.delete(url).headers(header_map).build()?;
25068 let info = OperationInfo {
25069 operation_id: "delete_spending_plan_iteration_item",
25070 };
25071 self.pre(&mut request, &info).await?;
25072 let result = self.exec(request, &info).await;
25073 self.post(&result, &info).await?;
25074 let response = result?;
25075 match response.status().as_u16() {
25076 204u16 => Ok(ResponseValue::empty(response)),
25077 _ => Err(Error::UnexpectedResponse(response)),
25078 }
25079 }
25080
25081 ///Read a spending plan for a user
25082 ///
25083 ///Use this endpoint to read the attributes of a specific spending plan
25084 /// according to its unique GUID.
25085 ///
25086 ///Sends a `GET` request to
25087 /// `/users/{user_guid}/spending_plans/{spending_plan_guid}`
25088 ///
25089 ///Arguments:
25090 /// - `user_guid`: The unique identifier for a `user`, beginning with the
25091 /// prefix `USR-`.
25092 /// - `spending_plan_guid`: The unique ID for the `spending_plan`.
25093 /// - `page`: Results are paginated. Specify current page.
25094 /// - `records_per_page`: This specifies the number of records to be
25095 /// returned on each page. Defaults to `25`. The valid range is from `10`
25096 /// to `1000`. If the value exceeds `1000`, the default value of `25` will
25097 /// be used instead.
25098 pub async fn read_spending_plan_user<'a>(
25099 &'a self,
25100 user_guid: &'a str,
25101 spending_plan_guid: &'a str,
25102 page: Option<i64>,
25103 records_per_page: Option<i64>,
25104 ) -> Result<ResponseValue<types::SpendingPlanResponse>, Error<()>> {
25105 let url = format!(
25106 "{}/users/{}/spending_plans/{}",
25107 self.baseurl,
25108 encode_path(&user_guid.to_string()),
25109 encode_path(&spending_plan_guid.to_string()),
25110 );
25111 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
25112 header_map.append(
25113 ::reqwest::header::HeaderName::from_static("api-version"),
25114 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
25115 );
25116 #[allow(unused_mut)]
25117 let mut request = self
25118 .client
25119 .get(url)
25120 .header(
25121 ::reqwest::header::ACCEPT,
25122 ::reqwest::header::HeaderValue::from_static("application/json"),
25123 )
25124 .query(&progenitor_client::QueryParam::new("page", &page))
25125 .query(&progenitor_client::QueryParam::new(
25126 "records_per_page",
25127 &records_per_page,
25128 ))
25129 .headers(header_map)
25130 .build()?;
25131 let info = OperationInfo {
25132 operation_id: "read_spending_plan_user",
25133 };
25134 self.pre(&mut request, &info).await?;
25135 let result = self.exec(request, &info).await;
25136 self.post(&result, &info).await?;
25137 let response = result?;
25138 match response.status().as_u16() {
25139 200u16 => ResponseValue::from_response(response).await,
25140 _ => Err(Error::UnexpectedResponse(response)),
25141 }
25142 }
25143
25144 ///Delete spending plan
25145 ///
25146 ///Use this endpoint to delete a user's `spending_plan`.
25147 ///
25148 ///Sends a `DELETE` request to
25149 /// `/users/{user_guid}/spending_plans/{spending_plan_guid}`
25150 ///
25151 ///Arguments:
25152 /// - `user_guid`: The unique identifier for a `user`, beginning with the
25153 /// prefix `USR-`.
25154 /// - `spending_plan_guid`: The unique ID for the `spending_plan`.
25155 pub async fn delete_spending_plan<'a>(
25156 &'a self,
25157 user_guid: &'a str,
25158 spending_plan_guid: &'a str,
25159 ) -> Result<ResponseValue<()>, Error<()>> {
25160 let url = format!(
25161 "{}/users/{}/spending_plans/{}",
25162 self.baseurl,
25163 encode_path(&user_guid.to_string()),
25164 encode_path(&spending_plan_guid.to_string()),
25165 );
25166 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
25167 header_map.append(
25168 ::reqwest::header::HeaderName::from_static("api-version"),
25169 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
25170 );
25171 #[allow(unused_mut)]
25172 let mut request = self.client.delete(url).headers(header_map).build()?;
25173 let info = OperationInfo {
25174 operation_id: "delete_spending_plan",
25175 };
25176 self.pre(&mut request, &info).await?;
25177 let result = self.exec(request, &info).await;
25178 self.post(&result, &info).await?;
25179 let response = result?;
25180 match response.status().as_u16() {
25181 204u16 => Ok(ResponseValue::empty(response)),
25182 _ => Err(Error::UnexpectedResponse(response)),
25183 }
25184 }
25185
25186 ///List spending plan accounts
25187 ///
25188 ///Use this endpoint to list all the spending plan accounts associated with
25189 /// the spending plan.
25190 ///
25191 ///Sends a `GET` request to
25192 /// `/users/{user_guid}/spending_plans/{spending_plan_guid}/
25193 /// spending_plan_accounts`
25194 ///
25195 ///Arguments:
25196 /// - `user_guid`: The unique identifier for a `user`, beginning with the
25197 /// prefix `USR-`.
25198 /// - `spending_plan_guid`: The unique ID for the `spending_plan`.
25199 /// - `page`: Results are paginated. Specify current page.
25200 /// - `records_per_page`: This specifies the number of records to be
25201 /// returned on each page. Defaults to `25`. The valid range is from `10`
25202 /// to `1000`. If the value exceeds `1000`, the default value of `25` will
25203 /// be used instead.
25204 pub async fn list_spending_plan_accounts<'a>(
25205 &'a self,
25206 user_guid: &'a str,
25207 spending_plan_guid: &'a str,
25208 page: Option<i64>,
25209 records_per_page: Option<i64>,
25210 ) -> Result<ResponseValue<types::SpendingPlanAccountsResponse>, Error<()>> {
25211 let url = format!(
25212 "{}/users/{}/spending_plans/{}/spending_plan_accounts",
25213 self.baseurl,
25214 encode_path(&user_guid.to_string()),
25215 encode_path(&spending_plan_guid.to_string()),
25216 );
25217 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
25218 header_map.append(
25219 ::reqwest::header::HeaderName::from_static("api-version"),
25220 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
25221 );
25222 #[allow(unused_mut)]
25223 let mut request = self
25224 .client
25225 .get(url)
25226 .header(
25227 ::reqwest::header::ACCEPT,
25228 ::reqwest::header::HeaderValue::from_static("application/json"),
25229 )
25230 .query(&progenitor_client::QueryParam::new("page", &page))
25231 .query(&progenitor_client::QueryParam::new(
25232 "records_per_page",
25233 &records_per_page,
25234 ))
25235 .headers(header_map)
25236 .build()?;
25237 let info = OperationInfo {
25238 operation_id: "list_spending_plan_accounts",
25239 };
25240 self.pre(&mut request, &info).await?;
25241 let result = self.exec(request, &info).await;
25242 self.post(&result, &info).await?;
25243 let response = result?;
25244 match response.status().as_u16() {
25245 200u16 => ResponseValue::from_response(response).await,
25246 _ => Err(Error::UnexpectedResponse(response)),
25247 }
25248 }
25249
25250 ///List spending plan iterations
25251 ///
25252 ///Use this endpoint to list all the spending plan `iterations` associated
25253 /// with the `spending_plan`.
25254 ///
25255 ///Sends a `GET` request to
25256 /// `/users/{user_guid}/spending_plans/{spending_plan_guid}/iterations`
25257 ///
25258 ///Arguments:
25259 /// - `user_guid`: The unique identifier for a `user`, beginning with the
25260 /// prefix `USR-`.
25261 /// - `spending_plan_guid`: The unique ID for the `spending_plan`.
25262 /// - `page`: Results are paginated. Specify current page.
25263 /// - `records_per_page`: This specifies the number of records to be
25264 /// returned on each page. Defaults to `25`. The valid range is from `10`
25265 /// to `1000`. If the value exceeds `1000`, the default value of `25` will
25266 /// be used instead.
25267 pub async fn list_spending_plan_iterations<'a>(
25268 &'a self,
25269 user_guid: &'a str,
25270 spending_plan_guid: &'a str,
25271 page: Option<i64>,
25272 records_per_page: Option<i64>,
25273 ) -> Result<ResponseValue<types::SpendingPlanIterationsResponse>, Error<()>> {
25274 let url = format!(
25275 "{}/users/{}/spending_plans/{}/iterations",
25276 self.baseurl,
25277 encode_path(&user_guid.to_string()),
25278 encode_path(&spending_plan_guid.to_string()),
25279 );
25280 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
25281 header_map.append(
25282 ::reqwest::header::HeaderName::from_static("api-version"),
25283 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
25284 );
25285 #[allow(unused_mut)]
25286 let mut request = self
25287 .client
25288 .get(url)
25289 .header(
25290 ::reqwest::header::ACCEPT,
25291 ::reqwest::header::HeaderValue::from_static("application/json"),
25292 )
25293 .query(&progenitor_client::QueryParam::new("page", &page))
25294 .query(&progenitor_client::QueryParam::new(
25295 "records_per_page",
25296 &records_per_page,
25297 ))
25298 .headers(header_map)
25299 .build()?;
25300 let info = OperationInfo {
25301 operation_id: "list_spending_plan_iterations",
25302 };
25303 self.pre(&mut request, &info).await?;
25304 let result = self.exec(request, &info).await;
25305 self.post(&result, &info).await?;
25306 let response = result?;
25307 match response.status().as_u16() {
25308 200u16 => ResponseValue::from_response(response).await,
25309 _ => Err(Error::UnexpectedResponse(response)),
25310 }
25311 }
25312
25313 ///Read current spending plan iteration
25314 ///
25315 ///Use this endpoint to read the attributes of the current spending plan
25316 /// `iteration`.
25317 ///
25318 ///Sends a `GET` request to
25319 /// `/users/{user_guid}/spending_plans/{spending_plan_guid}/iterations/
25320 /// current`
25321 ///
25322 ///Arguments:
25323 /// - `user_guid`: The unique identifier for a `user`, beginning with the
25324 /// prefix `USR-`.
25325 /// - `spending_plan_guid`: The unique ID for the `spending_plan`.
25326 /// - `page`: Results are paginated. Specify current page.
25327 /// - `records_per_page`: This specifies the number of records to be
25328 /// returned on each page. Defaults to `25`. The valid range is from `10`
25329 /// to `1000`. If the value exceeds `1000`, the default value of `25` will
25330 /// be used instead.
25331 pub async fn read_current_spending_plan_iteration<'a>(
25332 &'a self,
25333 user_guid: &'a str,
25334 spending_plan_guid: &'a str,
25335 page: Option<i64>,
25336 records_per_page: Option<i64>,
25337 ) -> Result<ResponseValue<types::SpendingPlanIterationResponse>, Error<()>> {
25338 let url = format!(
25339 "{}/users/{}/spending_plans/{}/iterations/current",
25340 self.baseurl,
25341 encode_path(&user_guid.to_string()),
25342 encode_path(&spending_plan_guid.to_string()),
25343 );
25344 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
25345 header_map.append(
25346 ::reqwest::header::HeaderName::from_static("api-version"),
25347 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
25348 );
25349 #[allow(unused_mut)]
25350 let mut request = self
25351 .client
25352 .get(url)
25353 .header(
25354 ::reqwest::header::ACCEPT,
25355 ::reqwest::header::HeaderValue::from_static("application/json"),
25356 )
25357 .query(&progenitor_client::QueryParam::new("page", &page))
25358 .query(&progenitor_client::QueryParam::new(
25359 "records_per_page",
25360 &records_per_page,
25361 ))
25362 .headers(header_map)
25363 .build()?;
25364 let info = OperationInfo {
25365 operation_id: "read_current_spending_plan_iteration",
25366 };
25367 self.pre(&mut request, &info).await?;
25368 let result = self.exec(request, &info).await;
25369 self.post(&result, &info).await?;
25370 let response = result?;
25371 match response.status().as_u16() {
25372 200u16 => ResponseValue::from_response(response).await,
25373 _ => Err(Error::UnexpectedResponse(response)),
25374 }
25375 }
25376
25377 ///Read a spending plan iteration
25378 ///
25379 ///Use this endpoint to read the attributes of a specific spending plan
25380 /// `iteration` according to its `iteration_number`.
25381 ///
25382 ///Sends a `GET` request to
25383 /// `/users/{user_guid}/spending_plans/{spending_plan_guid}/iterations/
25384 /// {iteration_number}`
25385 ///
25386 ///Arguments:
25387 /// - `user_guid`: The unique identifier for a `user`, beginning with the
25388 /// prefix `USR-`.
25389 /// - `spending_plan_guid`: The unique ID for the `spending_plan`.
25390 /// - `iteration_number`: The current iteration number for the spending plan
25391 /// `iteration`.
25392 /// - `page`: Results are paginated. Specify current page.
25393 /// - `records_per_page`: This specifies the number of records to be
25394 /// returned on each page. Defaults to `25`. The valid range is from `10`
25395 /// to `1000`. If the value exceeds `1000`, the default value of `25` will
25396 /// be used instead.
25397 pub async fn read_spending_plan_iteration<'a>(
25398 &'a self,
25399 user_guid: &'a str,
25400 spending_plan_guid: &'a str,
25401 iteration_number: i64,
25402 page: Option<i64>,
25403 records_per_page: Option<i64>,
25404 ) -> Result<ResponseValue<types::SpendingPlanIterationResponse>, Error<()>> {
25405 let url = format!(
25406 "{}/users/{}/spending_plans/{}/iterations/{}",
25407 self.baseurl,
25408 encode_path(&user_guid.to_string()),
25409 encode_path(&spending_plan_guid.to_string()),
25410 encode_path(&iteration_number.to_string()),
25411 );
25412 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
25413 header_map.append(
25414 ::reqwest::header::HeaderName::from_static("api-version"),
25415 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
25416 );
25417 #[allow(unused_mut)]
25418 let mut request = self
25419 .client
25420 .get(url)
25421 .header(
25422 ::reqwest::header::ACCEPT,
25423 ::reqwest::header::HeaderValue::from_static("application/json"),
25424 )
25425 .query(&progenitor_client::QueryParam::new("page", &page))
25426 .query(&progenitor_client::QueryParam::new(
25427 "records_per_page",
25428 &records_per_page,
25429 ))
25430 .headers(header_map)
25431 .build()?;
25432 let info = OperationInfo {
25433 operation_id: "read_spending_plan_iteration",
25434 };
25435 self.pre(&mut request, &info).await?;
25436 let result = self.exec(request, &info).await;
25437 self.post(&result, &info).await?;
25438 let response = result?;
25439 match response.status().as_u16() {
25440 200u16 => ResponseValue::from_response(response).await,
25441 _ => Err(Error::UnexpectedResponse(response)),
25442 }
25443 }
25444
25445 ///List taggings
25446 ///
25447 ///Use this endpoint to retrieve a list of all the taggings associated with
25448 /// a specific user.
25449 ///
25450 ///Sends a `GET` request to `/users/{user_guid}/taggings`
25451 ///
25452 ///Arguments:
25453 /// - `user_guid`: The unique identifier for a `user`, beginning with the
25454 /// prefix `USR-`.
25455 /// - `page`: Results are paginated. Specify current page.
25456 /// - `records_per_page`: This specifies the number of records to be
25457 /// returned on each page. Defaults to `25`. The valid range is from `10`
25458 /// to `1000`. If the value exceeds `1000`, the default value of `25` will
25459 /// be used instead.
25460 pub async fn list_taggings<'a>(
25461 &'a self,
25462 user_guid: &'a str,
25463 page: Option<i64>,
25464 records_per_page: Option<i64>,
25465 ) -> Result<ResponseValue<types::TaggingsResponseBody>, Error<()>> {
25466 let url = format!(
25467 "{}/users/{}/taggings",
25468 self.baseurl,
25469 encode_path(&user_guid.to_string()),
25470 );
25471 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
25472 header_map.append(
25473 ::reqwest::header::HeaderName::from_static("api-version"),
25474 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
25475 );
25476 #[allow(unused_mut)]
25477 let mut request = self
25478 .client
25479 .get(url)
25480 .header(
25481 ::reqwest::header::ACCEPT,
25482 ::reqwest::header::HeaderValue::from_static("application/json"),
25483 )
25484 .query(&progenitor_client::QueryParam::new("page", &page))
25485 .query(&progenitor_client::QueryParam::new(
25486 "records_per_page",
25487 &records_per_page,
25488 ))
25489 .headers(header_map)
25490 .build()?;
25491 let info = OperationInfo {
25492 operation_id: "list_taggings",
25493 };
25494 self.pre(&mut request, &info).await?;
25495 let result = self.exec(request, &info).await;
25496 self.post(&result, &info).await?;
25497 let response = result?;
25498 match response.status().as_u16() {
25499 200u16 => ResponseValue::from_response(response).await,
25500 _ => Err(Error::UnexpectedResponse(response)),
25501 }
25502 }
25503
25504 ///Create tagging
25505 ///
25506 ///Use this endpoint to create a new association between a tag and a
25507 /// particular transaction, according to their unique GUIDs.
25508 ///
25509 ///Sends a `POST` request to `/users/{user_guid}/taggings`
25510 ///
25511 ///Arguments:
25512 /// - `user_guid`: The unique identifier for a `user`, beginning with the
25513 /// prefix `USR-`.
25514 /// - `body`: Tagging object to be created with required parameters
25515 /// (tag_guid and transaction_guid)
25516 pub async fn create_tagging<'a>(
25517 &'a self,
25518 user_guid: &'a str,
25519 body: &'a types::TaggingCreateRequestBody,
25520 ) -> Result<ResponseValue<types::TaggingResponseBody>, Error<()>> {
25521 let url = format!(
25522 "{}/users/{}/taggings",
25523 self.baseurl,
25524 encode_path(&user_guid.to_string()),
25525 );
25526 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
25527 header_map.append(
25528 ::reqwest::header::HeaderName::from_static("api-version"),
25529 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
25530 );
25531 #[allow(unused_mut)]
25532 let mut request = self
25533 .client
25534 .post(url)
25535 .header(
25536 ::reqwest::header::ACCEPT,
25537 ::reqwest::header::HeaderValue::from_static("application/json"),
25538 )
25539 .json(&body)
25540 .headers(header_map)
25541 .build()?;
25542 let info = OperationInfo {
25543 operation_id: "create_tagging",
25544 };
25545 self.pre(&mut request, &info).await?;
25546 let result = self.exec(request, &info).await;
25547 self.post(&result, &info).await?;
25548 let response = result?;
25549 match response.status().as_u16() {
25550 200u16 => ResponseValue::from_response(response).await,
25551 _ => Err(Error::UnexpectedResponse(response)),
25552 }
25553 }
25554
25555 ///Read tagging
25556 ///
25557 ///Use this endpoint to read the attributes of a `tagging` according to its
25558 /// unique GUID.
25559 ///
25560 ///Sends a `GET` request to `/users/{user_guid}/taggings/{tagging_guid}`
25561 ///
25562 ///Arguments:
25563 /// - `user_guid`: The unique identifier for a `user`, beginning with the
25564 /// prefix `USR-`.
25565 /// - `tagging_guid`: The unique id for a `tagging`.
25566 pub async fn read_tagging<'a>(
25567 &'a self,
25568 user_guid: &'a str,
25569 tagging_guid: &'a str,
25570 ) -> Result<ResponseValue<types::TaggingResponseBody>, Error<()>> {
25571 let url = format!(
25572 "{}/users/{}/taggings/{}",
25573 self.baseurl,
25574 encode_path(&user_guid.to_string()),
25575 encode_path(&tagging_guid.to_string()),
25576 );
25577 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
25578 header_map.append(
25579 ::reqwest::header::HeaderName::from_static("api-version"),
25580 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
25581 );
25582 #[allow(unused_mut)]
25583 let mut request = self
25584 .client
25585 .get(url)
25586 .header(
25587 ::reqwest::header::ACCEPT,
25588 ::reqwest::header::HeaderValue::from_static("application/json"),
25589 )
25590 .headers(header_map)
25591 .build()?;
25592 let info = OperationInfo {
25593 operation_id: "read_tagging",
25594 };
25595 self.pre(&mut request, &info).await?;
25596 let result = self.exec(request, &info).await;
25597 self.post(&result, &info).await?;
25598 let response = result?;
25599 match response.status().as_u16() {
25600 200u16 => ResponseValue::from_response(response).await,
25601 _ => Err(Error::UnexpectedResponse(response)),
25602 }
25603 }
25604
25605 ///Update tagging
25606 ///
25607 ///Use this endpoint to update a tagging.
25608 ///
25609 ///Sends a `PUT` request to `/users/{user_guid}/taggings/{tagging_guid}`
25610 ///
25611 ///Arguments:
25612 /// - `user_guid`: The unique identifier for a `user`, beginning with the
25613 /// prefix `USR-`.
25614 /// - `tagging_guid`: The unique id for a `tagging`.
25615 /// - `body`: Tagging object to be updated with required parameter
25616 /// (tag_guid)
25617 pub async fn update_tagging<'a>(
25618 &'a self,
25619 user_guid: &'a str,
25620 tagging_guid: &'a str,
25621 body: &'a types::TaggingUpdateRequestBody,
25622 ) -> Result<ResponseValue<types::TaggingResponseBody>, Error<()>> {
25623 let url = format!(
25624 "{}/users/{}/taggings/{}",
25625 self.baseurl,
25626 encode_path(&user_guid.to_string()),
25627 encode_path(&tagging_guid.to_string()),
25628 );
25629 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
25630 header_map.append(
25631 ::reqwest::header::HeaderName::from_static("api-version"),
25632 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
25633 );
25634 #[allow(unused_mut)]
25635 let mut request = self
25636 .client
25637 .put(url)
25638 .header(
25639 ::reqwest::header::ACCEPT,
25640 ::reqwest::header::HeaderValue::from_static("application/json"),
25641 )
25642 .json(&body)
25643 .headers(header_map)
25644 .build()?;
25645 let info = OperationInfo {
25646 operation_id: "update_tagging",
25647 };
25648 self.pre(&mut request, &info).await?;
25649 let result = self.exec(request, &info).await;
25650 self.post(&result, &info).await?;
25651 let response = result?;
25652 match response.status().as_u16() {
25653 200u16 => ResponseValue::from_response(response).await,
25654 _ => Err(Error::UnexpectedResponse(response)),
25655 }
25656 }
25657
25658 ///Delete tagging
25659 ///
25660 ///Use this endpoint to delete a tagging according to its unique GUID. If
25661 /// successful, the API will respond with an empty body and a status of 204
25662 /// NO Content.
25663 ///
25664 ///Sends a `DELETE` request to `/users/{user_guid}/taggings/{tagging_guid}`
25665 ///
25666 ///Arguments:
25667 /// - `user_guid`: The unique identifier for a `user`, beginning with the
25668 /// prefix `USR-`.
25669 /// - `tagging_guid`: The unique id for a `tagging`.
25670 pub async fn delete_tagging<'a>(
25671 &'a self,
25672 user_guid: &'a str,
25673 tagging_guid: &'a str,
25674 ) -> Result<ResponseValue<()>, Error<()>> {
25675 let url = format!(
25676 "{}/users/{}/taggings/{}",
25677 self.baseurl,
25678 encode_path(&user_guid.to_string()),
25679 encode_path(&tagging_guid.to_string()),
25680 );
25681 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
25682 header_map.append(
25683 ::reqwest::header::HeaderName::from_static("api-version"),
25684 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
25685 );
25686 #[allow(unused_mut)]
25687 let mut request = self.client.delete(url).headers(header_map).build()?;
25688 let info = OperationInfo {
25689 operation_id: "delete_tagging",
25690 };
25691 self.pre(&mut request, &info).await?;
25692 let result = self.exec(request, &info).await;
25693 self.post(&result, &info).await?;
25694 let response = result?;
25695 match response.status().as_u16() {
25696 204u16 => Ok(ResponseValue::empty(response)),
25697 _ => Err(Error::UnexpectedResponse(response)),
25698 }
25699 }
25700
25701 ///List tags
25702 ///
25703 ///Use this endpoint to list all tags associated with the specified `user`.
25704 /// Each user includes the `Business` tag by default.
25705 ///
25706 ///Sends a `GET` request to `/users/{user_guid}/tags`
25707 ///
25708 ///Arguments:
25709 /// - `user_guid`: The unique identifier for a `user`, beginning with the
25710 /// prefix `USR-`.
25711 /// - `page`: Results are paginated. Specify current page.
25712 /// - `records_per_page`: This specifies the number of records to be
25713 /// returned on each page. Defaults to `25`. The valid range is from `10`
25714 /// to `1000`. If the value exceeds `1000`, the default value of `25` will
25715 /// be used instead.
25716 pub async fn list_tags<'a>(
25717 &'a self,
25718 user_guid: &'a str,
25719 page: Option<i64>,
25720 records_per_page: Option<i64>,
25721 ) -> Result<ResponseValue<types::TagsResponseBody>, Error<()>> {
25722 let url = format!(
25723 "{}/users/{}/tags",
25724 self.baseurl,
25725 encode_path(&user_guid.to_string()),
25726 );
25727 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
25728 header_map.append(
25729 ::reqwest::header::HeaderName::from_static("api-version"),
25730 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
25731 );
25732 #[allow(unused_mut)]
25733 let mut request = self
25734 .client
25735 .get(url)
25736 .header(
25737 ::reqwest::header::ACCEPT,
25738 ::reqwest::header::HeaderValue::from_static("application/json"),
25739 )
25740 .query(&progenitor_client::QueryParam::new("page", &page))
25741 .query(&progenitor_client::QueryParam::new(
25742 "records_per_page",
25743 &records_per_page,
25744 ))
25745 .headers(header_map)
25746 .build()?;
25747 let info = OperationInfo {
25748 operation_id: "list_tags",
25749 };
25750 self.pre(&mut request, &info).await?;
25751 let result = self.exec(request, &info).await;
25752 self.post(&result, &info).await?;
25753 let response = result?;
25754 match response.status().as_u16() {
25755 200u16 => ResponseValue::from_response(response).await,
25756 _ => Err(Error::UnexpectedResponse(response)),
25757 }
25758 }
25759
25760 ///Create tag
25761 ///
25762 ///Use this endpoint to create a new custom tag.
25763 ///
25764 ///Sends a `POST` request to `/users/{user_guid}/tags`
25765 ///
25766 ///Arguments:
25767 /// - `user_guid`: The unique identifier for a `user`, beginning with the
25768 /// prefix `USR-`.
25769 /// - `body`: Tag object to be created with required parameters (tag_guid)
25770 pub async fn create_tag<'a>(
25771 &'a self,
25772 user_guid: &'a str,
25773 body: &'a types::TagCreateRequestBody,
25774 ) -> Result<ResponseValue<types::TagResponseBody>, Error<()>> {
25775 let url = format!(
25776 "{}/users/{}/tags",
25777 self.baseurl,
25778 encode_path(&user_guid.to_string()),
25779 );
25780 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
25781 header_map.append(
25782 ::reqwest::header::HeaderName::from_static("api-version"),
25783 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
25784 );
25785 #[allow(unused_mut)]
25786 let mut request = self
25787 .client
25788 .post(url)
25789 .header(
25790 ::reqwest::header::ACCEPT,
25791 ::reqwest::header::HeaderValue::from_static("application/json"),
25792 )
25793 .json(&body)
25794 .headers(header_map)
25795 .build()?;
25796 let info = OperationInfo {
25797 operation_id: "create_tag",
25798 };
25799 self.pre(&mut request, &info).await?;
25800 let result = self.exec(request, &info).await;
25801 self.post(&result, &info).await?;
25802 let response = result?;
25803 match response.status().as_u16() {
25804 200u16 => ResponseValue::from_response(response).await,
25805 _ => Err(Error::UnexpectedResponse(response)),
25806 }
25807 }
25808
25809 ///Read tag
25810 ///
25811 ///Use this endpoint to read the attributes of a particular tag according
25812 /// to its unique GUID.
25813 ///
25814 ///Sends a `GET` request to `/users/{user_guid}/tags/{tag_guid}`
25815 ///
25816 ///Arguments:
25817 /// - `user_guid`: The unique identifier for a `user`, beginning with the
25818 /// prefix `USR-`.
25819 /// - `tag_guid`: The unique id for a `tag`.
25820 pub async fn read_tag<'a>(
25821 &'a self,
25822 user_guid: &'a str,
25823 tag_guid: &'a str,
25824 ) -> Result<ResponseValue<types::TagResponseBody>, Error<()>> {
25825 let url = format!(
25826 "{}/users/{}/tags/{}",
25827 self.baseurl,
25828 encode_path(&user_guid.to_string()),
25829 encode_path(&tag_guid.to_string()),
25830 );
25831 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
25832 header_map.append(
25833 ::reqwest::header::HeaderName::from_static("api-version"),
25834 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
25835 );
25836 #[allow(unused_mut)]
25837 let mut request = self
25838 .client
25839 .get(url)
25840 .header(
25841 ::reqwest::header::ACCEPT,
25842 ::reqwest::header::HeaderValue::from_static("application/json"),
25843 )
25844 .headers(header_map)
25845 .build()?;
25846 let info = OperationInfo {
25847 operation_id: "read_tag",
25848 };
25849 self.pre(&mut request, &info).await?;
25850 let result = self.exec(request, &info).await;
25851 self.post(&result, &info).await?;
25852 let response = result?;
25853 match response.status().as_u16() {
25854 200u16 => ResponseValue::from_response(response).await,
25855 _ => Err(Error::UnexpectedResponse(response)),
25856 }
25857 }
25858
25859 ///Update tag
25860 ///
25861 ///Use this endpoint to update the name of a specific tag according to its
25862 /// unique GUID.
25863 ///
25864 ///Sends a `PUT` request to `/users/{user_guid}/tags/{tag_guid}`
25865 ///
25866 ///Arguments:
25867 /// - `user_guid`: The unique identifier for a `user`, beginning with the
25868 /// prefix `USR-`.
25869 /// - `tag_guid`: The unique id for a `tag`.
25870 /// - `body`: Tag object to be updated with required parameter (tag_guid)
25871 pub async fn update_tag<'a>(
25872 &'a self,
25873 user_guid: &'a str,
25874 tag_guid: &'a str,
25875 body: &'a types::TagUpdateRequestBody,
25876 ) -> Result<ResponseValue<types::TagResponseBody>, Error<()>> {
25877 let url = format!(
25878 "{}/users/{}/tags/{}",
25879 self.baseurl,
25880 encode_path(&user_guid.to_string()),
25881 encode_path(&tag_guid.to_string()),
25882 );
25883 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
25884 header_map.append(
25885 ::reqwest::header::HeaderName::from_static("api-version"),
25886 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
25887 );
25888 #[allow(unused_mut)]
25889 let mut request = self
25890 .client
25891 .put(url)
25892 .header(
25893 ::reqwest::header::ACCEPT,
25894 ::reqwest::header::HeaderValue::from_static("application/json"),
25895 )
25896 .json(&body)
25897 .headers(header_map)
25898 .build()?;
25899 let info = OperationInfo {
25900 operation_id: "update_tag",
25901 };
25902 self.pre(&mut request, &info).await?;
25903 let result = self.exec(request, &info).await;
25904 self.post(&result, &info).await?;
25905 let response = result?;
25906 match response.status().as_u16() {
25907 200u16 => ResponseValue::from_response(response).await,
25908 _ => Err(Error::UnexpectedResponse(response)),
25909 }
25910 }
25911
25912 ///Delete tag
25913 ///
25914 ///Use this endpoint to permanently delete a specific tag based on its
25915 /// unique GUID. If successful, the API will respond with status of `204 No
25916 /// Content`.
25917 ///
25918 ///Sends a `DELETE` request to `/users/{user_guid}/tags/{tag_guid}`
25919 ///
25920 ///Arguments:
25921 /// - `user_guid`: The unique identifier for a `user`, beginning with the
25922 /// prefix `USR-`.
25923 /// - `tag_guid`: The unique id for a `tag`.
25924 /// - `accept`: Specifies the media type expected in the response.
25925 pub async fn delete_tag<'a>(
25926 &'a self,
25927 user_guid: &'a str,
25928 tag_guid: &'a str,
25929 accept: &'a str,
25930 ) -> Result<ResponseValue<()>, Error<()>> {
25931 let url = format!(
25932 "{}/users/{}/tags/{}",
25933 self.baseurl,
25934 encode_path(&user_guid.to_string()),
25935 encode_path(&tag_guid.to_string()),
25936 );
25937 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(2usize);
25938 header_map.append(
25939 ::reqwest::header::HeaderName::from_static("api-version"),
25940 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
25941 );
25942 header_map.append("Accept", accept.to_string().try_into()?);
25943 #[allow(unused_mut)]
25944 let mut request = self.client.delete(url).headers(header_map).build()?;
25945 let info = OperationInfo {
25946 operation_id: "delete_tag",
25947 };
25948 self.pre(&mut request, &info).await?;
25949 let result = self.exec(request, &info).await;
25950 self.post(&result, &info).await?;
25951 let response = result?;
25952 match response.status().as_u16() {
25953 204u16 => Ok(ResponseValue::empty(response)),
25954 _ => Err(Error::UnexpectedResponse(response)),
25955 }
25956 }
25957
25958 ///List transactions by tag
25959 ///
25960 ///Use this endpoint to get a list of all transactions associated with a
25961 /// particular tag according to the tag's unique GUID. This lists all
25962 /// transactions that have been assigned to a particular tag using the
25963 /// create tagging endpoint. <br /><br />Enhanced transaction data may be
25964 /// requested using the `includes` parameter. To use this optional
25965 /// parameter, the value should include the optional metadata requested such
25966 /// as `repeating_transactions`, `merchants`, `classifications`,
25967 /// `geolocations`. For more information, see the [Optional Enhancement
25968 /// Query Parameter
25969 /// guide](/api-reference/platform-api/reference/transactions-overview#
25970 /// enhanced-transactions#optional-enhancement-query-parameter).
25971 ///
25972 ///Sends a `GET` request to
25973 /// `/users/{user_guid}/tags/{tag_guid}/transactions`
25974 ///
25975 ///Arguments:
25976 /// - `user_guid`: The unique identifier for a `user`, beginning with the
25977 /// prefix `USR-`.
25978 /// - `tag_guid`: The unique id for a `tag`.
25979 /// - `category_guid`: Filter transactions belonging to specified
25980 /// `category_guid`.
25981 ///
25982 ///For example, `?category_guid=CAT-7829f71c-2e8c-afa5-2f55-fa3634b89874`.
25983 /// - `category_guid`: Filter transactions belonging to any specified
25984 /// `category_guid[]` in url.
25985 ///
25986 ///For example,
25987 /// `?category_guid[]=CAT-7829f71c-2e8c-afa5-2f55-fa3634b89874`.
25988 /// - `from_created_at`: Filter transactions from the date the transaction
25989 /// was created. This only supports ISO 8601 format without timestamp
25990 /// (YYYY-MM-DD). Maximum date range limit is 6 months.
25991 /// - `from_date`: Filter transactions from this date. This only supports
25992 /// ISO 8601 format without timestamp (YYYY-MM-DD). Defaults to 120 days
25993 /// ago if not provided.
25994 /// - `from_updated_at`: Filter transactions from the date in which the
25995 /// transaction was updated. This only supports ISO 8601 format without
25996 /// timestamp (YYYY-MM-DD). Maximum date range limit is 6 months.
25997 /// - `includes`: Options for enhanced transactions. This query parameter is
25998 /// optional. Possible additional metadata: `repeating_transactions`,
25999 /// `merchants`, `classifications`, `geolocations`. The query value is
26000 /// format sensitive. To retrieve all available enhancements, append:
26001 ///
26002 ///`?includes=repeating_transactions,merchants,classifications,
26003 /// geolocations`.
26004 ///
26005 ///The query options may be combined to specific enhancements. For example,
26006 /// to request Repeating Transactions and Geolocation data, use:
26007 ///
26008 ///`?includes=repeating_transactions,geolocations`.
26009 ///
26010 /// - Repeating Transactions: Identifies transactions with predictable
26011 /// recurrence patterns (e.g., Bill, Income, Subscription).
26012 /// - Merchants: Enriches transactions with merchant name.
26013 /// - Classifications: Provides more insight into the type of money movement
26014 /// that is occurring on the transaction, whether it be retail or
26015 /// investments.
26016 /// - Geolocation: Provides geographic metadata.
26017 ///
26018 /// - `page`: Results are paginated. Specify current page.
26019 /// - `records_per_page`: This specifies the number of records to be
26020 /// returned on each page. Defaults to `25`. The valid range is from `10`
26021 /// to `1000`. If the value exceeds `1000`, the default value of `25` will
26022 /// be used instead.
26023 /// - `to_created_at`: Filter transaction to the date in which the
26024 /// transaction was created. This only supports ISO 8601 format without
26025 /// timestamp (YYYY-MM-DD). Maximum date range limit is 6 months.
26026 /// - `to_date`: Filter transactions to this date (at midnight). This only
26027 /// supports ISO 8601 format without timestamp (YYYY-MM-DD). Defaults to 5
26028 /// days forward from the day the request is made to capture pending
26029 /// transactions.
26030 /// - `to_updated_at`: Filter transactions to the date in which the
26031 /// transaction was updated. This only supports ISO 8601 format without
26032 /// timestamp (YYYY-MM-DD). Maximum date range limit is 6 months.
26033 /// - `top_level_category_guid`: Filter transactions belonging to specified
26034 /// `top_level_category_guid`. This must be top level category guid, use
26035 /// `category_guid` for subcategory guid.
26036 ///
26037 ///For example,
26038 /// `?top_level_category_guid=CAT-7829f71c-2e8c-afa5-2f55-fa3634b89874`.
26039 /// - `top_level_category_guid`: Filter transactions belonging to any
26040 /// specified `top_level_category_guid[]` in url. This must be top level
26041 /// category guid(s), use `category_guid` for subcategory guid(s).
26042 ///
26043 ///For example,
26044 /// `?top_level_category_guid[]=CAT-7829f71c-2e8c-afa5-2f55-fa3634b89874`.
26045 /// - `use_case`: The use case associated with the member. Valid values are
26046 /// `PFM` and `MONEY_MOVEMENT`. For example, you can append either
26047 /// `?use_case=PFM` or `?use_case=MONEY_MOVEMENT`.
26048 pub async fn list_transactions_by_tag<'a>(
26049 &'a self,
26050 user_guid: &'a str,
26051 tag_guid: &'a str,
26052 category_guid: Option<&'a str>,
26053 from_created_at: Option<&'a str>,
26054 from_date: Option<&'a str>,
26055 from_updated_at: Option<&'a str>,
26056 includes: Option<&'a str>,
26057 page: Option<i64>,
26058 records_per_page: Option<i64>,
26059 to_created_at: Option<&'a str>,
26060 to_date: Option<&'a str>,
26061 to_updated_at: Option<&'a str>,
26062 top_level_category_guid: Option<&'a str>,
26063 use_case: Option<&'a str>,
26064 ) -> Result<ResponseValue<types::TransactionsResponseBodyIncludes>, Error<()>> {
26065 let url = format!(
26066 "{}/users/{}/tags/{}/transactions",
26067 self.baseurl,
26068 encode_path(&user_guid.to_string()),
26069 encode_path(&tag_guid.to_string()),
26070 );
26071 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
26072 header_map.append(
26073 ::reqwest::header::HeaderName::from_static("api-version"),
26074 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
26075 );
26076 #[allow(unused_mut)]
26077 let mut request = self
26078 .client
26079 .get(url)
26080 .header(
26081 ::reqwest::header::ACCEPT,
26082 ::reqwest::header::HeaderValue::from_static("application/json"),
26083 )
26084 .query(&progenitor_client::QueryParam::new(
26085 "category_guid",
26086 &category_guid,
26087 ))
26088 .query(&progenitor_client::QueryParam::new(
26089 "category_guid[]",
26090 &category_guid,
26091 ))
26092 .query(&progenitor_client::QueryParam::new(
26093 "from_created_at",
26094 &from_created_at,
26095 ))
26096 .query(&progenitor_client::QueryParam::new("from_date", &from_date))
26097 .query(&progenitor_client::QueryParam::new(
26098 "from_updated_at",
26099 &from_updated_at,
26100 ))
26101 .query(&progenitor_client::QueryParam::new("includes", &includes))
26102 .query(&progenitor_client::QueryParam::new("page", &page))
26103 .query(&progenitor_client::QueryParam::new(
26104 "records_per_page",
26105 &records_per_page,
26106 ))
26107 .query(&progenitor_client::QueryParam::new(
26108 "to_created_at",
26109 &to_created_at,
26110 ))
26111 .query(&progenitor_client::QueryParam::new("to_date", &to_date))
26112 .query(&progenitor_client::QueryParam::new(
26113 "to_updated_at",
26114 &to_updated_at,
26115 ))
26116 .query(&progenitor_client::QueryParam::new(
26117 "top_level_category_guid",
26118 &top_level_category_guid,
26119 ))
26120 .query(&progenitor_client::QueryParam::new(
26121 "top_level_category_guid[]",
26122 &top_level_category_guid,
26123 ))
26124 .query(&progenitor_client::QueryParam::new("use_case", &use_case))
26125 .headers(header_map)
26126 .build()?;
26127 let info = OperationInfo {
26128 operation_id: "list_transactions_by_tag",
26129 };
26130 self.pre(&mut request, &info).await?;
26131 let result = self.exec(request, &info).await;
26132 self.post(&result, &info).await?;
26133 let response = result?;
26134 match response.status().as_u16() {
26135 200u16 => ResponseValue::from_response(response).await,
26136 _ => Err(Error::UnexpectedResponse(response)),
26137 }
26138 }
26139
26140 ///List transaction rules
26141 ///
26142 ///Use this endpoint to read the attributes of all existing transaction
26143 /// rules belonging to the user.
26144 ///
26145 ///Sends a `GET` request to `/users/{user_guid}/transaction_rules`
26146 ///
26147 ///Arguments:
26148 /// - `user_guid`: The unique identifier for a `user`, beginning with the
26149 /// prefix `USR-`.
26150 /// - `page`: Results are paginated. Specify current page.
26151 /// - `records_per_page`: This specifies the number of records to be
26152 /// returned on each page. Defaults to `25`. The valid range is from `10`
26153 /// to `1000`. If the value exceeds `1000`, the default value of `25` will
26154 /// be used instead.
26155 pub async fn list_transaction_rules<'a>(
26156 &'a self,
26157 user_guid: &'a str,
26158 page: Option<i64>,
26159 records_per_page: Option<i64>,
26160 ) -> Result<ResponseValue<types::TransactionRulesResponseBody>, Error<()>> {
26161 let url = format!(
26162 "{}/users/{}/transaction_rules",
26163 self.baseurl,
26164 encode_path(&user_guid.to_string()),
26165 );
26166 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
26167 header_map.append(
26168 ::reqwest::header::HeaderName::from_static("api-version"),
26169 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
26170 );
26171 #[allow(unused_mut)]
26172 let mut request = self
26173 .client
26174 .get(url)
26175 .header(
26176 ::reqwest::header::ACCEPT,
26177 ::reqwest::header::HeaderValue::from_static("application/json"),
26178 )
26179 .query(&progenitor_client::QueryParam::new("page", &page))
26180 .query(&progenitor_client::QueryParam::new(
26181 "records_per_page",
26182 &records_per_page,
26183 ))
26184 .headers(header_map)
26185 .build()?;
26186 let info = OperationInfo {
26187 operation_id: "list_transaction_rules",
26188 };
26189 self.pre(&mut request, &info).await?;
26190 let result = self.exec(request, &info).await;
26191 self.post(&result, &info).await?;
26192 let response = result?;
26193 match response.status().as_u16() {
26194 200u16 => ResponseValue::from_response(response).await,
26195 _ => Err(Error::UnexpectedResponse(response)),
26196 }
26197 }
26198
26199 ///Create transaction rule
26200 ///
26201 ///Use this endpoint to create a new transaction rule. The newly-created
26202 /// `transaction_rule` object will be returned if successful.
26203 ///
26204 ///Sends a `POST` request to `/users/{user_guid}/transaction_rules`
26205 ///
26206 ///Arguments:
26207 /// - `user_guid`: The unique identifier for a `user`, beginning with the
26208 /// prefix `USR-`.
26209 /// - `body`: TransactionRule object to be created with optional parameters
26210 /// (description) and required parameters (category_guid and
26211 /// match_description)
26212 pub async fn create_transaction_rule<'a>(
26213 &'a self,
26214 user_guid: &'a str,
26215 body: &'a types::TransactionRuleCreateRequestBody,
26216 ) -> Result<ResponseValue<types::TransactionRuleResponseBody>, Error<()>> {
26217 let url = format!(
26218 "{}/users/{}/transaction_rules",
26219 self.baseurl,
26220 encode_path(&user_guid.to_string()),
26221 );
26222 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
26223 header_map.append(
26224 ::reqwest::header::HeaderName::from_static("api-version"),
26225 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
26226 );
26227 #[allow(unused_mut)]
26228 let mut request = self
26229 .client
26230 .post(url)
26231 .header(
26232 ::reqwest::header::ACCEPT,
26233 ::reqwest::header::HeaderValue::from_static("application/json"),
26234 )
26235 .json(&body)
26236 .headers(header_map)
26237 .build()?;
26238 let info = OperationInfo {
26239 operation_id: "create_transaction_rule",
26240 };
26241 self.pre(&mut request, &info).await?;
26242 let result = self.exec(request, &info).await;
26243 self.post(&result, &info).await?;
26244 let response = result?;
26245 match response.status().as_u16() {
26246 200u16 => ResponseValue::from_response(response).await,
26247 _ => Err(Error::UnexpectedResponse(response)),
26248 }
26249 }
26250
26251 ///Read transaction rule
26252 ///
26253 ///Use this endpoint to read the attributes of an existing transaction rule
26254 /// based on the rule’s unique GUID.
26255 ///
26256 ///Sends a `GET` request to
26257 /// `/users/{user_guid}/transaction_rules/{transaction_rule_guid}`
26258 ///
26259 ///Arguments:
26260 /// - `user_guid`: The unique identifier for a `user`, beginning with the
26261 /// prefix `USR-`.
26262 /// - `transaction_rule_guid`: The unique id for a `transaction_rule`.
26263 pub async fn read_transaction_rule<'a>(
26264 &'a self,
26265 user_guid: &'a str,
26266 transaction_rule_guid: &'a str,
26267 ) -> Result<ResponseValue<types::TransactionRuleResponseBody>, Error<()>> {
26268 let url = format!(
26269 "{}/users/{}/transaction_rules/{}",
26270 self.baseurl,
26271 encode_path(&user_guid.to_string()),
26272 encode_path(&transaction_rule_guid.to_string()),
26273 );
26274 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
26275 header_map.append(
26276 ::reqwest::header::HeaderName::from_static("api-version"),
26277 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
26278 );
26279 #[allow(unused_mut)]
26280 let mut request = self
26281 .client
26282 .get(url)
26283 .header(
26284 ::reqwest::header::ACCEPT,
26285 ::reqwest::header::HeaderValue::from_static("application/json"),
26286 )
26287 .headers(header_map)
26288 .build()?;
26289 let info = OperationInfo {
26290 operation_id: "read_transaction_rule",
26291 };
26292 self.pre(&mut request, &info).await?;
26293 let result = self.exec(request, &info).await;
26294 self.post(&result, &info).await?;
26295 let response = result?;
26296 match response.status().as_u16() {
26297 200u16 => ResponseValue::from_response(response).await,
26298 _ => Err(Error::UnexpectedResponse(response)),
26299 }
26300 }
26301
26302 ///Update transaction rule
26303 ///
26304 ///Use this endpoint to update the attributes of a specific transaction
26305 /// rule based on its unique GUID. The API will respond with the updated
26306 /// transaction_rule object. Any attributes not provided will be left
26307 /// unchanged.
26308 ///
26309 ///Sends a `PUT` request to
26310 /// `/users/{user_guid}/transaction_rules/{transaction_rule_guid}`
26311 ///
26312 ///Arguments:
26313 /// - `user_guid`: The unique identifier for a `user`, beginning with the
26314 /// prefix `USR-`.
26315 /// - `transaction_rule_guid`: The unique id for a `transaction_rule`.
26316 /// - `body`: TransactionRule object to be updated
26317 pub async fn update_transaction_rule<'a>(
26318 &'a self,
26319 user_guid: &'a str,
26320 transaction_rule_guid: &'a str,
26321 body: &'a types::TransactionRuleUpdateRequestBody,
26322 ) -> Result<ResponseValue<types::TransactionRuleResponseBody>, Error<()>> {
26323 let url = format!(
26324 "{}/users/{}/transaction_rules/{}",
26325 self.baseurl,
26326 encode_path(&user_guid.to_string()),
26327 encode_path(&transaction_rule_guid.to_string()),
26328 );
26329 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
26330 header_map.append(
26331 ::reqwest::header::HeaderName::from_static("api-version"),
26332 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
26333 );
26334 #[allow(unused_mut)]
26335 let mut request = self
26336 .client
26337 .put(url)
26338 .header(
26339 ::reqwest::header::ACCEPT,
26340 ::reqwest::header::HeaderValue::from_static("application/json"),
26341 )
26342 .json(&body)
26343 .headers(header_map)
26344 .build()?;
26345 let info = OperationInfo {
26346 operation_id: "update_transaction_rule",
26347 };
26348 self.pre(&mut request, &info).await?;
26349 let result = self.exec(request, &info).await;
26350 self.post(&result, &info).await?;
26351 let response = result?;
26352 match response.status().as_u16() {
26353 200u16 => ResponseValue::from_response(response).await,
26354 _ => Err(Error::UnexpectedResponse(response)),
26355 }
26356 }
26357
26358 ///Delete transaction rule
26359 ///
26360 ///Use this endpoint to permanently delete a transaction rule based on its
26361 /// unique GUID.
26362 ///
26363 ///Sends a `DELETE` request to
26364 /// `/users/{user_guid}/transaction_rules/{transaction_rule_guid}`
26365 ///
26366 ///Arguments:
26367 /// - `user_guid`: The unique identifier for a `user`, beginning with the
26368 /// prefix `USR-`.
26369 /// - `transaction_rule_guid`: The unique id for a `transaction_rule`.
26370 pub async fn delete_transaction_rule<'a>(
26371 &'a self,
26372 user_guid: &'a str,
26373 transaction_rule_guid: &'a str,
26374 ) -> Result<ResponseValue<()>, Error<()>> {
26375 let url = format!(
26376 "{}/users/{}/transaction_rules/{}",
26377 self.baseurl,
26378 encode_path(&user_guid.to_string()),
26379 encode_path(&transaction_rule_guid.to_string()),
26380 );
26381 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
26382 header_map.append(
26383 ::reqwest::header::HeaderName::from_static("api-version"),
26384 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
26385 );
26386 #[allow(unused_mut)]
26387 let mut request = self.client.delete(url).headers(header_map).build()?;
26388 let info = OperationInfo {
26389 operation_id: "delete_transaction_rule",
26390 };
26391 self.pre(&mut request, &info).await?;
26392 let result = self.exec(request, &info).await;
26393 self.post(&result, &info).await?;
26394 let response = result?;
26395 match response.status().as_u16() {
26396 204u16 => Ok(ResponseValue::empty(response)),
26397 _ => Err(Error::UnexpectedResponse(response)),
26398 }
26399 }
26400
26401 ///List transactions
26402 ///
26403 ///Requests to this endpoint return a list of transactions associated with
26404 /// the specified `user`, across all members and accounts associated with
26405 /// that `user`. <br /><br />Enhanced transaction data may be requested
26406 /// using the `includes` parameter. To use this optional parameter, the
26407 /// value should include the optional metadata requested such as
26408 /// `repeating_transactions`, `merchants`, `classifications`,
26409 /// `geolocations`. For more information, see the [Optional Enhancement
26410 /// Query Parameter
26411 /// guide](/api-reference/platform-api/reference/transactions-overview#
26412 /// enhanced-transactions#optional-enhancement-query-parameter).
26413 ///
26414 ///Sends a `GET` request to `/users/{user_guid}/transactions`
26415 ///
26416 ///Arguments:
26417 /// - `user_guid`: The unique identifier for a `user`, beginning with the
26418 /// prefix `USR-`.
26419 /// - `category_guid`: Filter transactions belonging to specified
26420 /// `category_guid`.
26421 ///
26422 ///For example, `?category_guid=CAT-7829f71c-2e8c-afa5-2f55-fa3634b89874`.
26423 /// - `category_guid`: Filter transactions belonging to any specified
26424 /// `category_guid[]` in url.
26425 ///
26426 ///For example,
26427 /// `?category_guid[]=CAT-7829f71c-2e8c-afa5-2f55-fa3634b89874`.
26428 /// - `from_created_at`: Filter transactions from the date the transaction
26429 /// was created. This only supports ISO 8601 format without timestamp
26430 /// (YYYY-MM-DD). Maximum date range limit is 6 months.
26431 /// - `from_date`: Filter transactions from this date. This only supports
26432 /// ISO 8601 format without timestamp (YYYY-MM-DD). Defaults to 120 days
26433 /// ago if not provided.
26434 /// - `from_updated_at`: Filter transactions from the date in which the
26435 /// transaction was updated. This only supports ISO 8601 format without
26436 /// timestamp (YYYY-MM-DD). Maximum date range limit is 6 months.
26437 /// - `includes`: Options for enhanced transactions. This query parameter is
26438 /// optional. Possible additional metadata: `repeating_transactions`,
26439 /// `merchants`, `classifications`, `geolocations`. The query value is
26440 /// format sensitive. To retrieve all available enhancements, append:
26441 ///
26442 ///`?includes=repeating_transactions,merchants,classifications,
26443 /// geolocations`.
26444 ///
26445 ///The query options may be combined to specific enhancements. For example,
26446 /// to request Repeating Transactions and Geolocation data, use:
26447 ///
26448 ///`?includes=repeating_transactions,geolocations`.
26449 ///
26450 /// - Repeating Transactions: Identifies transactions with predictable
26451 /// recurrence patterns (e.g., Bill, Income, Subscription).
26452 /// - Merchants: Enriches transactions with merchant name.
26453 /// - Classifications: Provides more insight into the type of money movement
26454 /// that is occurring on the transaction, whether it be retail or
26455 /// investments.
26456 /// - Geolocation: Provides geographic metadata.
26457 ///
26458 /// - `page`: Results are paginated. Specify current page.
26459 /// - `records_per_page`: This specifies the number of records to be
26460 /// returned on each page. Defaults to `25`. The valid range is from `10`
26461 /// to `1000`. If the value exceeds `1000`, the default value of `25` will
26462 /// be used instead.
26463 /// - `to_created_at`: Filter transaction to the date in which the
26464 /// transaction was created. This only supports ISO 8601 format without
26465 /// timestamp (YYYY-MM-DD). Maximum date range limit is 6 months.
26466 /// - `to_date`: Filter transactions to this date (at midnight). This only
26467 /// supports ISO 8601 format without timestamp (YYYY-MM-DD). Defaults to 5
26468 /// days forward from the day the request is made to capture pending
26469 /// transactions.
26470 /// - `to_updated_at`: Filter transactions to the date in which the
26471 /// transaction was updated. This only supports ISO 8601 format without
26472 /// timestamp (YYYY-MM-DD). Maximum date range limit is 6 months.
26473 /// - `top_level_category_guid`: Filter transactions belonging to specified
26474 /// `top_level_category_guid`. This must be top level category guid, use
26475 /// `category_guid` for subcategory guid.
26476 ///
26477 ///For example,
26478 /// `?top_level_category_guid=CAT-7829f71c-2e8c-afa5-2f55-fa3634b89874`.
26479 /// - `top_level_category_guid`: Filter transactions belonging to any
26480 /// specified `top_level_category_guid[]` in url. This must be top level
26481 /// category guid(s), use `category_guid` for subcategory guid(s).
26482 ///
26483 ///For example,
26484 /// `?top_level_category_guid[]=CAT-7829f71c-2e8c-afa5-2f55-fa3634b89874`.
26485 /// - `use_case`: The use case associated with the member. Valid values are
26486 /// `PFM` and `MONEY_MOVEMENT`. For example, you can append either
26487 /// `?use_case=PFM` or `?use_case=MONEY_MOVEMENT`.
26488 pub async fn list_transactions<'a>(
26489 &'a self,
26490 user_guid: &'a str,
26491 category_guid: Option<&'a str>,
26492 from_created_at: Option<&'a str>,
26493 from_date: Option<&'a str>,
26494 from_updated_at: Option<&'a str>,
26495 includes: Option<&'a str>,
26496 page: Option<i64>,
26497 records_per_page: Option<i64>,
26498 to_created_at: Option<&'a str>,
26499 to_date: Option<&'a str>,
26500 to_updated_at: Option<&'a str>,
26501 top_level_category_guid: Option<&'a str>,
26502 use_case: Option<&'a str>,
26503 ) -> Result<ResponseValue<types::TransactionsResponseBodyIncludes>, Error<()>> {
26504 let url = format!(
26505 "{}/users/{}/transactions",
26506 self.baseurl,
26507 encode_path(&user_guid.to_string()),
26508 );
26509 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
26510 header_map.append(
26511 ::reqwest::header::HeaderName::from_static("api-version"),
26512 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
26513 );
26514 #[allow(unused_mut)]
26515 let mut request = self
26516 .client
26517 .get(url)
26518 .header(
26519 ::reqwest::header::ACCEPT,
26520 ::reqwest::header::HeaderValue::from_static("application/json"),
26521 )
26522 .query(&progenitor_client::QueryParam::new(
26523 "category_guid",
26524 &category_guid,
26525 ))
26526 .query(&progenitor_client::QueryParam::new(
26527 "category_guid[]",
26528 &category_guid,
26529 ))
26530 .query(&progenitor_client::QueryParam::new(
26531 "from_created_at",
26532 &from_created_at,
26533 ))
26534 .query(&progenitor_client::QueryParam::new("from_date", &from_date))
26535 .query(&progenitor_client::QueryParam::new(
26536 "from_updated_at",
26537 &from_updated_at,
26538 ))
26539 .query(&progenitor_client::QueryParam::new("includes", &includes))
26540 .query(&progenitor_client::QueryParam::new("page", &page))
26541 .query(&progenitor_client::QueryParam::new(
26542 "records_per_page",
26543 &records_per_page,
26544 ))
26545 .query(&progenitor_client::QueryParam::new(
26546 "to_created_at",
26547 &to_created_at,
26548 ))
26549 .query(&progenitor_client::QueryParam::new("to_date", &to_date))
26550 .query(&progenitor_client::QueryParam::new(
26551 "to_updated_at",
26552 &to_updated_at,
26553 ))
26554 .query(&progenitor_client::QueryParam::new(
26555 "top_level_category_guid",
26556 &top_level_category_guid,
26557 ))
26558 .query(&progenitor_client::QueryParam::new(
26559 "top_level_category_guid[]",
26560 &top_level_category_guid,
26561 ))
26562 .query(&progenitor_client::QueryParam::new("use_case", &use_case))
26563 .headers(header_map)
26564 .build()?;
26565 let info = OperationInfo {
26566 operation_id: "list_transactions",
26567 };
26568 self.pre(&mut request, &info).await?;
26569 let result = self.exec(request, &info).await;
26570 self.post(&result, &info).await?;
26571 let response = result?;
26572 match response.status().as_u16() {
26573 200u16 => ResponseValue::from_response(response).await,
26574 _ => Err(Error::UnexpectedResponse(response)),
26575 }
26576 }
26577
26578 ///Read transaction
26579 ///
26580 ///Requests to this endpoint will return the attributes of the specified
26581 /// `transaction`. To read a manual transaction, use the manual transaction
26582 /// guid in the path as the `transactionGuid`. <br /><br />Enhanced
26583 /// transaction data may be requested using the `includes` parameter. To use
26584 /// this optional parameter, the value should include the optional metadata
26585 /// requested such as `repeating_transactions`, `merchants`,
26586 /// `classifications`, `geolocations`. For more information, see the
26587 /// [Optional Enhancement Query Parameter
26588 /// guide](/api-reference/platform-api/reference/transactions-overview#
26589 /// enhanced-transactions#optional-enhancement-query-parameter).
26590 ///
26591 ///Sends a `GET` request to
26592 /// `/users/{user_guid}/transactions/{transaction_guid}`
26593 ///
26594 ///Arguments:
26595 /// - `user_guid`: The unique identifier for a `user`, beginning with the
26596 /// prefix `USR-`.
26597 /// - `transaction_guid`: The unique id for a `transaction`.
26598 /// - `includes`: Options for enhanced transactions. This query parameter is
26599 /// optional. Possible additional metadata: `repeating_transactions`,
26600 /// `merchants`, `classifications`, `geolocations`. The query value is
26601 /// format sensitive. To retrieve all available enhancements, append:
26602 ///
26603 ///`?includes=repeating_transactions,merchants,classifications,
26604 /// geolocations`.
26605 ///
26606 ///The query options may be combined to specific enhancements. For example,
26607 /// to request Repeating Transactions and Geolocation data, use:
26608 ///
26609 ///`?includes=repeating_transactions,geolocations`.
26610 ///
26611 /// - Repeating Transactions: Identifies transactions with predictable
26612 /// recurrence patterns (e.g., Bill, Income, Subscription).
26613 /// - Merchants: Enriches transactions with merchant name.
26614 /// - Classifications: Provides more insight into the type of money movement
26615 /// that is occurring on the transaction, whether it be retail or
26616 /// investments.
26617 /// - Geolocation: Provides geographic metadata.
26618 pub async fn read_transaction<'a>(
26619 &'a self,
26620 user_guid: &'a str,
26621 transaction_guid: &'a str,
26622 includes: Option<&'a str>,
26623 ) -> Result<ResponseValue<types::TransactionsResponseBodyIncludes>, Error<()>> {
26624 let url = format!(
26625 "{}/users/{}/transactions/{}",
26626 self.baseurl,
26627 encode_path(&user_guid.to_string()),
26628 encode_path(&transaction_guid.to_string()),
26629 );
26630 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
26631 header_map.append(
26632 ::reqwest::header::HeaderName::from_static("api-version"),
26633 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
26634 );
26635 #[allow(unused_mut)]
26636 let mut request = self
26637 .client
26638 .get(url)
26639 .header(
26640 ::reqwest::header::ACCEPT,
26641 ::reqwest::header::HeaderValue::from_static("application/json"),
26642 )
26643 .query(&progenitor_client::QueryParam::new("includes", &includes))
26644 .headers(header_map)
26645 .build()?;
26646 let info = OperationInfo {
26647 operation_id: "read_transaction",
26648 };
26649 self.pre(&mut request, &info).await?;
26650 let result = self.exec(request, &info).await;
26651 self.post(&result, &info).await?;
26652 let response = result?;
26653 match response.status().as_u16() {
26654 200u16 => ResponseValue::from_response(response).await,
26655 _ => Err(Error::UnexpectedResponse(response)),
26656 }
26657 }
26658
26659 ///Update transaction
26660 ///
26661 ///Use this endpoint to update a specific transaction according to its
26662 /// unique GUID.
26663 ///
26664 ///Sends a `PUT` request to
26665 /// `/users/{user_guid}/transactions/{transaction_guid}`
26666 ///
26667 ///Arguments:
26668 /// - `user_guid`: The unique identifier for a `user`, beginning with the
26669 /// prefix `USR-`.
26670 /// - `transaction_guid`: The unique id for a `transaction`.
26671 /// - `body`: Transaction object with the fields to be updated.
26672 pub async fn update_transaction<'a>(
26673 &'a self,
26674 user_guid: &'a str,
26675 transaction_guid: &'a str,
26676 body: &'a types::TransactionUpdateRequestBody,
26677 ) -> Result<ResponseValue<types::TransactionResponseBody>, Error<()>> {
26678 let url = format!(
26679 "{}/users/{}/transactions/{}",
26680 self.baseurl,
26681 encode_path(&user_guid.to_string()),
26682 encode_path(&transaction_guid.to_string()),
26683 );
26684 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
26685 header_map.append(
26686 ::reqwest::header::HeaderName::from_static("api-version"),
26687 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
26688 );
26689 #[allow(unused_mut)]
26690 let mut request = self
26691 .client
26692 .put(url)
26693 .header(
26694 ::reqwest::header::ACCEPT,
26695 ::reqwest::header::HeaderValue::from_static("application/json"),
26696 )
26697 .json(&body)
26698 .headers(header_map)
26699 .build()?;
26700 let info = OperationInfo {
26701 operation_id: "update_transaction",
26702 };
26703 self.pre(&mut request, &info).await?;
26704 let result = self.exec(request, &info).await;
26705 self.post(&result, &info).await?;
26706 let response = result?;
26707 match response.status().as_u16() {
26708 200u16 => ResponseValue::from_response(response).await,
26709 _ => Err(Error::UnexpectedResponse(response)),
26710 }
26711 }
26712
26713 ///Delete manual transactions
26714 ///
26715 ///Delete a manual transaction. In the path, use the manual transaction
26716 /// guid as the `transaction_guid`, such as
26717 /// `MAN-810828b0-5210-4878-9bd3-f4ce514f90c4`.
26718 ///
26719 ///Sends a `DELETE` request to
26720 /// `/users/{user_guid}/transactions/{transaction_guid}`
26721 ///
26722 ///Arguments:
26723 /// - `user_guid`: The unique identifier for a `user`, beginning with the
26724 /// prefix `USR-`.
26725 /// - `transaction_guid`: The unique id for a `transaction`.
26726 pub async fn delete_manual_transactions<'a>(
26727 &'a self,
26728 user_guid: &'a str,
26729 transaction_guid: &'a str,
26730 ) -> Result<ResponseValue<()>, Error<()>> {
26731 let url = format!(
26732 "{}/users/{}/transactions/{}",
26733 self.baseurl,
26734 encode_path(&user_guid.to_string()),
26735 encode_path(&transaction_guid.to_string()),
26736 );
26737 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
26738 header_map.append(
26739 ::reqwest::header::HeaderName::from_static("api-version"),
26740 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
26741 );
26742 #[allow(unused_mut)]
26743 let mut request = self.client.delete(url).headers(header_map).build()?;
26744 let info = OperationInfo {
26745 operation_id: "delete_manual_transactions",
26746 };
26747 self.pre(&mut request, &info).await?;
26748 let result = self.exec(request, &info).await;
26749 self.post(&result, &info).await?;
26750 let response = result?;
26751 match response.status().as_u16() {
26752 204u16 => Ok(ResponseValue::empty(response)),
26753 _ => Err(Error::UnexpectedResponse(response)),
26754 }
26755 }
26756
26757 ///Request widget URL
26758 ///
26759 ///Get an embeddable URL for integrating a widget into your website or app.
26760 /// The URL expires after ten minutes or upon first use, whichever occurs
26761 /// first. You'll need to obtain a new URL each time the page loads or
26762 /// reloads.
26763 ///
26764 ///Include the `widget_type` in the request body to specify which widget
26765 /// you want to embed—the Connect Widget, a Personal Financial Management
26766 /// widget, or an Insights widget. Some request parameters are specific to
26767 /// certain widget types.
26768 ///
26769 ///To embed the Connect Widget, set `widget_type` to `connect_widget`.
26770 ///
26771 ///For a full list of available widget types, see [Widget
26772 /// Types](/api-reference/platform-api/reference/widgets#widget-types).
26773 ///
26774 ///
26775 ///Sends a `POST` request to `/users/{user_guid}/widget_urls`
26776 ///
26777 ///Arguments:
26778 /// - `user_guid`: The unique identifier for a `user`, beginning with the
26779 /// prefix `USR-`.
26780 /// - `accept_language`: The desired language of the widget.
26781 /// - `x_callback_payload`: The base64 encoded string defined in this header
26782 /// will be returned in the [Member](/resources/webhooks/member/) and
26783 /// [Member Data Updated](/resources/webhooks/member#member-data-updated)
26784 /// webhooks. This allows you to trace user interactions and workflows
26785 /// initiated externally and internally in the MX Platform. Max 1024
26786 /// characters.
26787 /// - `body`: The widget url configuration options.
26788 pub async fn request_widget_url<'a>(
26789 &'a self,
26790 user_guid: &'a str,
26791 accept_language: Option<&'a str>,
26792 x_callback_payload: Option<&'a str>,
26793 body: &'a types::WidgetRequestBody,
26794 ) -> Result<ResponseValue<types::WidgetResponseBody>, Error<()>> {
26795 let url = format!(
26796 "{}/users/{}/widget_urls",
26797 self.baseurl,
26798 encode_path(&user_guid.to_string()),
26799 );
26800 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(3usize);
26801 header_map.append(
26802 ::reqwest::header::HeaderName::from_static("api-version"),
26803 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
26804 );
26805 if let Some(value) = accept_language {
26806 header_map.append("Accept-Language", value.to_string().try_into()?);
26807 }
26808
26809 if let Some(value) = x_callback_payload {
26810 header_map.append("X-CALLBACK-PAYLOAD", value.to_string().try_into()?);
26811 }
26812
26813 #[allow(unused_mut)]
26814 let mut request = self
26815 .client
26816 .post(url)
26817 .header(
26818 ::reqwest::header::ACCEPT,
26819 ::reqwest::header::HeaderValue::from_static("application/json"),
26820 )
26821 .json(&body)
26822 .headers(header_map)
26823 .build()?;
26824 let info = OperationInfo {
26825 operation_id: "request_widget_url",
26826 };
26827 self.pre(&mut request, &info).await?;
26828 let result = self.exec(request, &info).await;
26829 self.post(&result, &info).await?;
26830 let response = result?;
26831 match response.status().as_u16() {
26832 200u16 => ResponseValue::from_response(response).await,
26833 _ => Err(Error::UnexpectedResponse(response)),
26834 }
26835 }
26836
26837 ///Auto-generate budgets
26838 ///
26839 ///This endpoint will automatically create budgets for several categories
26840 /// based on existing transactions; these budgets are returned as an array.
26841 /// Specifically, budgets will only be generated if the `user` has at least
26842 /// one `transaction` in a given category during each of the two previous
26843 /// calendar months. For example, if the request is made on March 6, and
26844 /// there is at least one "Bills & Utilities" `transaction` in both January
26845 /// and February, a budget will be generated for "Bills & Utilities." If
26846 /// there are two "Bills & Utilities" transactions in February but none in
26847 /// January, no budget will be generated for that category. If budgets
26848 /// already exist for particular categories, new budgets will be generated
26849 /// and returned based on the available transactions. If one or more budgets
26850 /// remain unchanged, they will nevertheless be returned in the response. If
26851 /// no transaction data for the `user` meet the above criteria, a `422
26852 /// Unprocessable Entity` error will be returned with status code 4221 along
26853 /// with the message, `There aren't enough transactions to automatically
26854 /// create any budgets`.
26855 ///
26856 ///Sends a `POST` request to `/users/{user_guid}/budgets/generate`
26857 ///
26858 ///Arguments:
26859 /// - `user_guid`: The unique identifier for a `user`, beginning with the
26860 /// prefix `USR-`.
26861 pub async fn auto_generate_budgets<'a>(
26862 &'a self,
26863 user_guid: &'a str,
26864 ) -> Result<ResponseValue<types::BudgetResponseBody>, Error<()>> {
26865 let url = format!(
26866 "{}/users/{}/budgets/generate",
26867 self.baseurl,
26868 encode_path(&user_guid.to_string()),
26869 );
26870 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
26871 header_map.append(
26872 ::reqwest::header::HeaderName::from_static("api-version"),
26873 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
26874 );
26875 #[allow(unused_mut)]
26876 let mut request = self
26877 .client
26878 .post(url)
26879 .header(
26880 ::reqwest::header::ACCEPT,
26881 ::reqwest::header::HeaderValue::from_static("application/json"),
26882 )
26883 .headers(header_map)
26884 .build()?;
26885 let info = OperationInfo {
26886 operation_id: "auto_generate_budgets",
26887 };
26888 self.pre(&mut request, &info).await?;
26889 let result = self.exec(request, &info).await;
26890 self.post(&result, &info).await?;
26891 let response = result?;
26892 match response.status().as_u16() {
26893 200u16 => ResponseValue::from_response(response).await,
26894 _ => Err(Error::UnexpectedResponse(response)),
26895 }
26896 }
26897
26898 ///List all budgets
26899 ///
26900 ///List all budgets
26901 ///
26902 ///Sends a `GET` request to `/users/{user_guid}/budgets`
26903 ///
26904 ///Arguments:
26905 /// - `user_guid`: The unique identifier for a `user`, beginning with the
26906 /// prefix `USR-`.
26907 pub async fn list_all_budgets<'a>(
26908 &'a self,
26909 user_guid: &'a str,
26910 ) -> Result<ResponseValue<types::BudgetResponseBody>, Error<()>> {
26911 let url = format!(
26912 "{}/users/{}/budgets",
26913 self.baseurl,
26914 encode_path(&user_guid.to_string()),
26915 );
26916 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
26917 header_map.append(
26918 ::reqwest::header::HeaderName::from_static("api-version"),
26919 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
26920 );
26921 #[allow(unused_mut)]
26922 let mut request = self
26923 .client
26924 .get(url)
26925 .header(
26926 ::reqwest::header::ACCEPT,
26927 ::reqwest::header::HeaderValue::from_static("application/json"),
26928 )
26929 .headers(header_map)
26930 .build()?;
26931 let info = OperationInfo {
26932 operation_id: "list_all_budgets",
26933 };
26934 self.pre(&mut request, &info).await?;
26935 let result = self.exec(request, &info).await;
26936 self.post(&result, &info).await?;
26937 let response = result?;
26938 match response.status().as_u16() {
26939 200u16 => ResponseValue::from_response(response).await,
26940 _ => Err(Error::UnexpectedResponse(response)),
26941 }
26942 }
26943
26944 ///Create a budget
26945 ///
26946 ///Create a budget. This endpoint accepts the optional `MX-Skip-Webhook`
26947 /// header and `skip_webhook` parameter. You cannot create a duplicate
26948 /// budget. For example, if you attempt to create a budget for "Gas", but
26949 /// that budget already exist, the request will fail. You can retrieve a
26950 /// list of all existing categories by using the List Categories endpoint.
26951 ///
26952 ///Sends a `POST` request to `/users/{user_guid}/budgets`
26953 ///
26954 ///Arguments:
26955 /// - `user_guid`: The unique identifier for a `user`, beginning with the
26956 /// prefix `USR-`.
26957 /// - `body`
26958 pub async fn create_budget<'a>(
26959 &'a self,
26960 user_guid: &'a str,
26961 body: &'a types::BudgetCreateRequestBody,
26962 ) -> Result<ResponseValue<types::BudgetResponseBody>, Error<()>> {
26963 let url = format!(
26964 "{}/users/{}/budgets",
26965 self.baseurl,
26966 encode_path(&user_guid.to_string()),
26967 );
26968 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
26969 header_map.append(
26970 ::reqwest::header::HeaderName::from_static("api-version"),
26971 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
26972 );
26973 #[allow(unused_mut)]
26974 let mut request = self
26975 .client
26976 .post(url)
26977 .header(
26978 ::reqwest::header::ACCEPT,
26979 ::reqwest::header::HeaderValue::from_static("application/json"),
26980 )
26981 .json(&body)
26982 .headers(header_map)
26983 .build()?;
26984 let info = OperationInfo {
26985 operation_id: "create_budget",
26986 };
26987 self.pre(&mut request, &info).await?;
26988 let result = self.exec(request, &info).await;
26989 self.post(&result, &info).await?;
26990 let response = result?;
26991 match response.status().as_u16() {
26992 200u16 => ResponseValue::from_response(response).await,
26993 _ => Err(Error::UnexpectedResponse(response)),
26994 }
26995 }
26996
26997 ///Read a specific budget
26998 ///
26999 ///Read a specific budget.
27000 ///
27001 ///Sends a `GET` request to `/users/{user_guid}/budgets/{budget_guid}`
27002 ///
27003 ///Arguments:
27004 /// - `user_guid`: The unique identifier for a `user`, beginning with the
27005 /// prefix `USR-`.
27006 /// - `budget_guid`: The unique identifier for the budget. Defined by MX.
27007 pub async fn read_specific_budget<'a>(
27008 &'a self,
27009 user_guid: &'a str,
27010 budget_guid: &'a str,
27011 ) -> Result<ResponseValue<types::BudgetResponseBody>, Error<()>> {
27012 let url = format!(
27013 "{}/users/{}/budgets/{}",
27014 self.baseurl,
27015 encode_path(&user_guid.to_string()),
27016 encode_path(&budget_guid.to_string()),
27017 );
27018 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
27019 header_map.append(
27020 ::reqwest::header::HeaderName::from_static("api-version"),
27021 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
27022 );
27023 #[allow(unused_mut)]
27024 let mut request = self
27025 .client
27026 .get(url)
27027 .header(
27028 ::reqwest::header::ACCEPT,
27029 ::reqwest::header::HeaderValue::from_static("application/json"),
27030 )
27031 .headers(header_map)
27032 .build()?;
27033 let info = OperationInfo {
27034 operation_id: "read_specific_budget",
27035 };
27036 self.pre(&mut request, &info).await?;
27037 let result = self.exec(request, &info).await;
27038 self.post(&result, &info).await?;
27039 let response = result?;
27040 match response.status().as_u16() {
27041 200u16 => ResponseValue::from_response(response).await,
27042 _ => Err(Error::UnexpectedResponse(response)),
27043 }
27044 }
27045
27046 ///Update a specific budget
27047 ///
27048 ///Update a specific budget.
27049 ///
27050 ///Sends a `PUT` request to `/users/{user_guid}/budgets/{budget_guid}`
27051 ///
27052 ///Arguments:
27053 /// - `user_guid`: The unique identifier for a `user`, beginning with the
27054 /// prefix `USR-`.
27055 /// - `budget_guid`: The unique identifier for the budget. Defined by MX.
27056 /// - `body`
27057 pub async fn update_specific_budget<'a>(
27058 &'a self,
27059 user_guid: &'a str,
27060 budget_guid: &'a str,
27061 body: &'a types::BudgetUpdateRequestBody,
27062 ) -> Result<ResponseValue<types::BudgetResponseBody>, Error<()>> {
27063 let url = format!(
27064 "{}/users/{}/budgets/{}",
27065 self.baseurl,
27066 encode_path(&user_guid.to_string()),
27067 encode_path(&budget_guid.to_string()),
27068 );
27069 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
27070 header_map.append(
27071 ::reqwest::header::HeaderName::from_static("api-version"),
27072 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
27073 );
27074 #[allow(unused_mut)]
27075 let mut request = self
27076 .client
27077 .put(url)
27078 .header(
27079 ::reqwest::header::ACCEPT,
27080 ::reqwest::header::HeaderValue::from_static("application/json"),
27081 )
27082 .json(&body)
27083 .headers(header_map)
27084 .build()?;
27085 let info = OperationInfo {
27086 operation_id: "update_specific_budget",
27087 };
27088 self.pre(&mut request, &info).await?;
27089 let result = self.exec(request, &info).await;
27090 self.post(&result, &info).await?;
27091 let response = result?;
27092 match response.status().as_u16() {
27093 200u16 => ResponseValue::from_response(response).await,
27094 _ => Err(Error::UnexpectedResponse(response)),
27095 }
27096 }
27097
27098 ///Delete a budget
27099 ///
27100 ///Delete a budget.
27101 ///
27102 ///Sends a `DELETE` request to `/users/{user_guid}/budgets/{budget_guid}`
27103 ///
27104 ///Arguments:
27105 /// - `user_guid`: The unique identifier for a `user`, beginning with the
27106 /// prefix `USR-`.
27107 /// - `budget_guid`: The unique identifier for the budget. Defined by MX.
27108 pub async fn delete_budget<'a>(
27109 &'a self,
27110 user_guid: &'a str,
27111 budget_guid: &'a str,
27112 ) -> Result<ResponseValue<()>, Error<()>> {
27113 let url = format!(
27114 "{}/users/{}/budgets/{}",
27115 self.baseurl,
27116 encode_path(&user_guid.to_string()),
27117 encode_path(&budget_guid.to_string()),
27118 );
27119 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
27120 header_map.append(
27121 ::reqwest::header::HeaderName::from_static("api-version"),
27122 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
27123 );
27124 #[allow(unused_mut)]
27125 let mut request = self.client.delete(url).headers(header_map).build()?;
27126 let info = OperationInfo {
27127 operation_id: "delete_budget",
27128 };
27129 self.pre(&mut request, &info).await?;
27130 let result = self.exec(request, &info).await;
27131 self.post(&result, &info).await?;
27132 let response = result?;
27133 match response.status().as_u16() {
27134 204u16 => Ok(ResponseValue::empty(response)),
27135 _ => Err(Error::UnexpectedResponse(response)),
27136 }
27137 }
27138
27139 ///List goals
27140 ///
27141 ///List all goals a user can set.
27142 ///
27143 ///Sends a `GET` request to `/users/{user_guid}/goals`
27144 ///
27145 ///Arguments:
27146 /// - `user_guid`: The unique identifier for a `user`, beginning with the
27147 /// prefix `USR-`.
27148 /// - `page`: Results are paginated. Specify current page.
27149 /// - `records_per_page`: This specifies the number of records to be
27150 /// returned on each page. Defaults to `25`. The valid range is from `10`
27151 /// to `1000`. If the value exceeds `1000`, the default value of `25` will
27152 /// be used instead.
27153 /// - `accept`: Specifies the media type expected in the response.
27154 pub async fn list_goals<'a>(
27155 &'a self,
27156 user_guid: &'a str,
27157 page: Option<i64>,
27158 records_per_page: Option<i64>,
27159 accept: &'a str,
27160 ) -> Result<ResponseValue<types::GoalsResponseBody>, Error<()>> {
27161 let url = format!(
27162 "{}/users/{}/goals",
27163 self.baseurl,
27164 encode_path(&user_guid.to_string()),
27165 );
27166 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(2usize);
27167 header_map.append(
27168 ::reqwest::header::HeaderName::from_static("api-version"),
27169 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
27170 );
27171 header_map.append("Accept", accept.to_string().try_into()?);
27172 #[allow(unused_mut)]
27173 let mut request = self
27174 .client
27175 .get(url)
27176 .header(
27177 ::reqwest::header::ACCEPT,
27178 ::reqwest::header::HeaderValue::from_static("application/json"),
27179 )
27180 .query(&progenitor_client::QueryParam::new("page", &page))
27181 .query(&progenitor_client::QueryParam::new(
27182 "records_per_page",
27183 &records_per_page,
27184 ))
27185 .headers(header_map)
27186 .build()?;
27187 let info = OperationInfo {
27188 operation_id: "list_goals",
27189 };
27190 self.pre(&mut request, &info).await?;
27191 let result = self.exec(request, &info).await;
27192 self.post(&result, &info).await?;
27193 let response = result?;
27194 match response.status().as_u16() {
27195 200u16 => ResponseValue::from_response(response).await,
27196 _ => Err(Error::UnexpectedResponse(response)),
27197 }
27198 }
27199
27200 ///Create a goal
27201 ///
27202 ///Create a goal. This endpoint accepts the optional `MX-Skip-Webhook`
27203 /// header and `skip_webhook` parameter.
27204 ///
27205 ///Sends a `POST` request to `/users/{user_guid}/goals`
27206 ///
27207 ///Arguments:
27208 /// - `user_guid`: The unique identifier for a `user`, beginning with the
27209 /// prefix `USR-`.
27210 /// - `body`
27211 pub async fn create_goal<'a>(
27212 &'a self,
27213 user_guid: &'a str,
27214 body: &'a types::GoalRequestBody,
27215 ) -> Result<ResponseValue<types::GoalResponseBody>, Error<()>> {
27216 let url = format!(
27217 "{}/users/{}/goals",
27218 self.baseurl,
27219 encode_path(&user_guid.to_string()),
27220 );
27221 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
27222 header_map.append(
27223 ::reqwest::header::HeaderName::from_static("api-version"),
27224 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
27225 );
27226 #[allow(unused_mut)]
27227 let mut request = self
27228 .client
27229 .post(url)
27230 .header(
27231 ::reqwest::header::ACCEPT,
27232 ::reqwest::header::HeaderValue::from_static("application/json"),
27233 )
27234 .json(&body)
27235 .headers(header_map)
27236 .build()?;
27237 let info = OperationInfo {
27238 operation_id: "create_goal",
27239 };
27240 self.pre(&mut request, &info).await?;
27241 let result = self.exec(request, &info).await;
27242 self.post(&result, &info).await?;
27243 let response = result?;
27244 match response.status().as_u16() {
27245 200u16 => ResponseValue::from_response(response).await,
27246 _ => Err(Error::UnexpectedResponse(response)),
27247 }
27248 }
27249
27250 ///Read a goal
27251 ///
27252 ///Read a specific goal.
27253 ///
27254 ///Sends a `GET` request to `/users/{user_guid}/goals/{goal_guid}`
27255 ///
27256 ///Arguments:
27257 /// - `user_guid`: The unique identifier for a `user`, beginning with the
27258 /// prefix `USR-`.
27259 /// - `goal_guid`: The unique identifier for a goal. Defined by MX.
27260 pub async fn read_goal<'a>(
27261 &'a self,
27262 user_guid: &'a str,
27263 goal_guid: &'a str,
27264 ) -> Result<ResponseValue<types::GoalResponseBody>, Error<()>> {
27265 let url = format!(
27266 "{}/users/{}/goals/{}",
27267 self.baseurl,
27268 encode_path(&user_guid.to_string()),
27269 encode_path(&goal_guid.to_string()),
27270 );
27271 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
27272 header_map.append(
27273 ::reqwest::header::HeaderName::from_static("api-version"),
27274 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
27275 );
27276 #[allow(unused_mut)]
27277 let mut request = self
27278 .client
27279 .get(url)
27280 .header(
27281 ::reqwest::header::ACCEPT,
27282 ::reqwest::header::HeaderValue::from_static("application/json"),
27283 )
27284 .headers(header_map)
27285 .build()?;
27286 let info = OperationInfo {
27287 operation_id: "read_goal",
27288 };
27289 self.pre(&mut request, &info).await?;
27290 let result = self.exec(request, &info).await;
27291 self.post(&result, &info).await?;
27292 let response = result?;
27293 match response.status().as_u16() {
27294 200u16 => ResponseValue::from_response(response).await,
27295 _ => Err(Error::UnexpectedResponse(response)),
27296 }
27297 }
27298
27299 ///Update a goal
27300 ///
27301 ///This endpoint updates a specific goal.
27302 ///
27303 ///Sends a `PUT` request to `/users/{user_guid}/goals/{goal_guid}`
27304 ///
27305 ///Arguments:
27306 /// - `user_guid`: The unique identifier for a `user`, beginning with the
27307 /// prefix `USR-`.
27308 /// - `goal_guid`: The unique identifier for a goal. Defined by MX.
27309 /// - `body`
27310 pub async fn update_goal<'a>(
27311 &'a self,
27312 user_guid: &'a str,
27313 goal_guid: &'a str,
27314 body: &'a types::UpdateGoalRequestBody,
27315 ) -> Result<ResponseValue<types::GoalResponseBody>, Error<()>> {
27316 let url = format!(
27317 "{}/users/{}/goals/{}",
27318 self.baseurl,
27319 encode_path(&user_guid.to_string()),
27320 encode_path(&goal_guid.to_string()),
27321 );
27322 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
27323 header_map.append(
27324 ::reqwest::header::HeaderName::from_static("api-version"),
27325 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
27326 );
27327 #[allow(unused_mut)]
27328 let mut request = self
27329 .client
27330 .put(url)
27331 .header(
27332 ::reqwest::header::ACCEPT,
27333 ::reqwest::header::HeaderValue::from_static("application/json"),
27334 )
27335 .json(&body)
27336 .headers(header_map)
27337 .build()?;
27338 let info = OperationInfo {
27339 operation_id: "update_goal",
27340 };
27341 self.pre(&mut request, &info).await?;
27342 let result = self.exec(request, &info).await;
27343 self.post(&result, &info).await?;
27344 let response = result?;
27345 match response.status().as_u16() {
27346 200u16 => ResponseValue::from_response(response).await,
27347 _ => Err(Error::UnexpectedResponse(response)),
27348 }
27349 }
27350
27351 ///Delete a goal
27352 ///
27353 ///Delete a goal.
27354 ///
27355 ///Sends a `DELETE` request to `/users/{user_guid}/goals/{goal_guid}`
27356 ///
27357 ///Arguments:
27358 /// - `user_guid`: The unique identifier for a `user`, beginning with the
27359 /// prefix `USR-`.
27360 /// - `goal_guid`: The unique identifier for a goal. Defined by MX.
27361 /// - `accept`: Specifies the media type expected in the response.
27362 pub async fn delete_goal<'a>(
27363 &'a self,
27364 user_guid: &'a str,
27365 goal_guid: &'a str,
27366 accept: &'a str,
27367 ) -> Result<ResponseValue<()>, Error<()>> {
27368 let url = format!(
27369 "{}/users/{}/goals/{}",
27370 self.baseurl,
27371 encode_path(&user_guid.to_string()),
27372 encode_path(&goal_guid.to_string()),
27373 );
27374 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(2usize);
27375 header_map.append(
27376 ::reqwest::header::HeaderName::from_static("api-version"),
27377 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
27378 );
27379 header_map.append("Accept", accept.to_string().try_into()?);
27380 #[allow(unused_mut)]
27381 let mut request = self.client.delete(url).headers(header_map).build()?;
27382 let info = OperationInfo {
27383 operation_id: "delete_goal",
27384 };
27385 self.pre(&mut request, &info).await?;
27386 let result = self.exec(request, &info).await;
27387 self.post(&result, &info).await?;
27388 let response = result?;
27389 match response.status().as_u16() {
27390 204u16 => Ok(ResponseValue::empty(response)),
27391 _ => Err(Error::UnexpectedResponse(response)),
27392 }
27393 }
27394
27395 ///Reposition goals
27396 ///
27397 ///This endpoint repositions goal priority levels. If one goal is set to a
27398 /// lower priority, then any other goals need to be adjusted accordingly.
27399 ///
27400 ///Sends a `PUT` request to `/users/{user_guid}/goals/reposition`
27401 ///
27402 ///Arguments:
27403 /// - `user_guid`: The unique identifier for a `user`, beginning with the
27404 /// prefix `USR-`.
27405 /// - `body`
27406 pub async fn reposition_goals<'a>(
27407 &'a self,
27408 user_guid: &'a str,
27409 body: &'a types::RepositionRequestBody,
27410 ) -> Result<ResponseValue<types::RepositionResponseBody>, Error<()>> {
27411 let url = format!(
27412 "{}/users/{}/goals/reposition",
27413 self.baseurl,
27414 encode_path(&user_guid.to_string()),
27415 );
27416 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
27417 header_map.append(
27418 ::reqwest::header::HeaderName::from_static("api-version"),
27419 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
27420 );
27421 #[allow(unused_mut)]
27422 let mut request = self
27423 .client
27424 .put(url)
27425 .header(
27426 ::reqwest::header::ACCEPT,
27427 ::reqwest::header::HeaderValue::from_static("application/json"),
27428 )
27429 .json(&body)
27430 .headers(header_map)
27431 .build()?;
27432 let info = OperationInfo {
27433 operation_id: "reposition_goals",
27434 };
27435 self.pre(&mut request, &info).await?;
27436 let result = self.exec(request, &info).await;
27437 self.post(&result, &info).await?;
27438 let response = result?;
27439 match response.status().as_u16() {
27440 200u16 => ResponseValue::from_response(response).await,
27441 _ => Err(Error::UnexpectedResponse(response)),
27442 }
27443 }
27444
27445 ///List notifications
27446 ///
27447 ///All notifications for the user can be listed, including notifications
27448 /// created by MX for other channels besides `PUSH`.
27449 ///
27450 ///Sends a `GET` request to `/users/{user_guid}/notifications`
27451 ///
27452 ///Arguments:
27453 /// - `user_guid`: The unique identifier for a `user`, beginning with the
27454 /// prefix `USR-`.
27455 /// - `from_date`: Filter transactions from this date. This only supports
27456 /// ISO 8601 format without timestamp (YYYY-MM-DD). Defaults to 120 days
27457 /// ago if not provided.
27458 /// - `page`: Results are paginated. Specify current page.
27459 /// - `records_per_page`: This specifies the number of records to be
27460 /// returned on each page. Defaults to `25`. The valid range is from `10`
27461 /// to `1000`. If the value exceeds `1000`, the default value of `25` will
27462 /// be used instead.
27463 /// - `to_date`: Filter transactions to this date (at midnight). This only
27464 /// supports ISO 8601 format without timestamp (YYYY-MM-DD). Defaults to 5
27465 /// days forward from the day the request is made to capture pending
27466 /// transactions.
27467 pub async fn list_notifications<'a>(
27468 &'a self,
27469 user_guid: &'a str,
27470 from_date: Option<&'a str>,
27471 page: Option<i64>,
27472 records_per_page: Option<i64>,
27473 to_date: Option<&'a str>,
27474 ) -> Result<ResponseValue<types::NotificationsResponseBody>, Error<()>> {
27475 let url = format!(
27476 "{}/users/{}/notifications",
27477 self.baseurl,
27478 encode_path(&user_guid.to_string()),
27479 );
27480 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
27481 header_map.append(
27482 ::reqwest::header::HeaderName::from_static("api-version"),
27483 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
27484 );
27485 #[allow(unused_mut)]
27486 let mut request = self
27487 .client
27488 .get(url)
27489 .header(
27490 ::reqwest::header::ACCEPT,
27491 ::reqwest::header::HeaderValue::from_static("application/json"),
27492 )
27493 .query(&progenitor_client::QueryParam::new("from_date", &from_date))
27494 .query(&progenitor_client::QueryParam::new("page", &page))
27495 .query(&progenitor_client::QueryParam::new(
27496 "records_per_page",
27497 &records_per_page,
27498 ))
27499 .query(&progenitor_client::QueryParam::new("to_date", &to_date))
27500 .headers(header_map)
27501 .build()?;
27502 let info = OperationInfo {
27503 operation_id: "list_notifications",
27504 };
27505 self.pre(&mut request, &info).await?;
27506 let result = self.exec(request, &info).await;
27507 self.post(&result, &info).await?;
27508 let response = result?;
27509 match response.status().as_u16() {
27510 200u16 => ResponseValue::from_response(response).await,
27511 _ => Err(Error::UnexpectedResponse(response)),
27512 }
27513 }
27514
27515 ///Create a notification
27516 ///
27517 ///All notifications created through the API will be of notification type
27518 /// `API_NOTIFICATION`, channel `PUSH`, and will not be associated to an
27519 /// entity. No other channels are supported. This will only have an effect
27520 /// for clients using an MX mobile application.
27521 ///
27522 ///Sends a `POST` request to `/users/{user_guid}/notifications`
27523 ///
27524 ///Arguments:
27525 /// - `user_guid`: The unique identifier for a `user`, beginning with the
27526 /// prefix `USR-`.
27527 /// - `content`: The information related to the notification.
27528 /// - `subject`: The subject related to the notification.
27529 pub async fn create_notification<'a>(
27530 &'a self,
27531 user_guid: &'a str,
27532 content: &'a str,
27533 subject: &'a str,
27534 ) -> Result<ResponseValue<types::NotificationResponseBody>, Error<()>> {
27535 let url = format!(
27536 "{}/users/{}/notifications",
27537 self.baseurl,
27538 encode_path(&user_guid.to_string()),
27539 );
27540 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
27541 header_map.append(
27542 ::reqwest::header::HeaderName::from_static("api-version"),
27543 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
27544 );
27545 #[allow(unused_mut)]
27546 let mut request = self
27547 .client
27548 .post(url)
27549 .header(
27550 ::reqwest::header::ACCEPT,
27551 ::reqwest::header::HeaderValue::from_static("application/json"),
27552 )
27553 .query(&progenitor_client::QueryParam::new("content", &content))
27554 .query(&progenitor_client::QueryParam::new("subject", &subject))
27555 .headers(header_map)
27556 .build()?;
27557 let info = OperationInfo {
27558 operation_id: "create_notification",
27559 };
27560 self.pre(&mut request, &info).await?;
27561 let result = self.exec(request, &info).await;
27562 self.post(&result, &info).await?;
27563 let response = result?;
27564 match response.status().as_u16() {
27565 200u16 => ResponseValue::from_response(response).await,
27566 _ => Err(Error::UnexpectedResponse(response)),
27567 }
27568 }
27569
27570 ///Read notifications
27571 ///
27572 ///Can pull up any notification associated with the user, including
27573 /// notifications created by MX for other channels besides `PUSH`.
27574 ///
27575 ///
27576 ///Sends a `GET` request to
27577 /// `/users/{user_guid}/notifications/{notification_guid}`
27578 ///
27579 ///Arguments:
27580 /// - `user_guid`: The unique identifier for a `user`, beginning with the
27581 /// prefix `USR-`.
27582 /// - `notification_guid`: The unique identifier for notifications. Defined
27583 /// by MX.
27584 pub async fn read_notifications<'a>(
27585 &'a self,
27586 user_guid: &'a str,
27587 notification_guid: &'a str,
27588 ) -> Result<ResponseValue<types::NotificationResponseBody>, Error<()>> {
27589 let url = format!(
27590 "{}/users/{}/notifications/{}",
27591 self.baseurl,
27592 encode_path(&user_guid.to_string()),
27593 encode_path(¬ification_guid.to_string()),
27594 );
27595 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
27596 header_map.append(
27597 ::reqwest::header::HeaderName::from_static("api-version"),
27598 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
27599 );
27600 #[allow(unused_mut)]
27601 let mut request = self
27602 .client
27603 .get(url)
27604 .header(
27605 ::reqwest::header::ACCEPT,
27606 ::reqwest::header::HeaderValue::from_static("application/json"),
27607 )
27608 .headers(header_map)
27609 .build()?;
27610 let info = OperationInfo {
27611 operation_id: "read_notifications",
27612 };
27613 self.pre(&mut request, &info).await?;
27614 let result = self.exec(request, &info).await;
27615 self.post(&result, &info).await?;
27616 let response = result?;
27617 match response.status().as_u16() {
27618 200u16 => ResponseValue::from_response(response).await,
27619 _ => Err(Error::UnexpectedResponse(response)),
27620 }
27621 }
27622
27623 ///List Repeating Transactions
27624 ///
27625 ///Retrieve a list of all recurring transactions for a user. <br /><br
27626 /// />For more see the [Repeating Transactions
27627 /// guide](repeating-transactions-overview.mdx).
27628 ///
27629 ///Sends a `GET` request to `/users/{user_guid}/repeating_transactions`
27630 ///
27631 ///Arguments:
27632 /// - `user_guid`: The unique identifier for a `user`, beginning with the
27633 /// prefix `USR-`.
27634 pub async fn repeating_transactions<'a>(
27635 &'a self,
27636 user_guid: &'a str,
27637 ) -> Result<ResponseValue<types::RepeatingTransactionsResponseBody>, Error<()>> {
27638 let url = format!(
27639 "{}/users/{}/repeating_transactions",
27640 self.baseurl,
27641 encode_path(&user_guid.to_string()),
27642 );
27643 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
27644 header_map.append(
27645 ::reqwest::header::HeaderName::from_static("api-version"),
27646 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
27647 );
27648 #[allow(unused_mut)]
27649 let mut request = self
27650 .client
27651 .get(url)
27652 .header(
27653 ::reqwest::header::ACCEPT,
27654 ::reqwest::header::HeaderValue::from_static("application/json"),
27655 )
27656 .headers(header_map)
27657 .build()?;
27658 let info = OperationInfo {
27659 operation_id: "repeating_transactions",
27660 };
27661 self.pre(&mut request, &info).await?;
27662 let result = self.exec(request, &info).await;
27663 self.post(&result, &info).await?;
27664 let response = result?;
27665 match response.status().as_u16() {
27666 200u16 => ResponseValue::from_response(response).await,
27667 _ => Err(Error::UnexpectedResponse(response)),
27668 }
27669 }
27670
27671 ///Get a Repeating Transaction
27672 ///
27673 ///Get a Specific Repeating Transaction. <br /><br />List For more see the
27674 /// [Repeating Transactions guide](repeating-transactions-overview.mdx)
27675 ///
27676 ///Sends a `GET` request to
27677 /// `/users/{user_guid}/repeating_transactions/{repeating_transaction_guid}`
27678 ///
27679 ///Arguments:
27680 /// - `user_guid`: The unique identifier for a `user`, beginning with the
27681 /// prefix `USR-`.
27682 /// - `repeating_transaction_guid`: The unique id for a recurring
27683 /// transaction.
27684 pub async fn specific_repeating_transaction<'a>(
27685 &'a self,
27686 user_guid: &'a str,
27687 repeating_transaction_guid: &'a str,
27688 ) -> Result<ResponseValue<types::RepeatingTransactionsResponseBody>, Error<()>> {
27689 let url = format!(
27690 "{}/users/{}/repeating_transactions/{}",
27691 self.baseurl,
27692 encode_path(&user_guid.to_string()),
27693 encode_path(&repeating_transaction_guid.to_string()),
27694 );
27695 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
27696 header_map.append(
27697 ::reqwest::header::HeaderName::from_static("api-version"),
27698 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
27699 );
27700 #[allow(unused_mut)]
27701 let mut request = self
27702 .client
27703 .get(url)
27704 .header(
27705 ::reqwest::header::ACCEPT,
27706 ::reqwest::header::HeaderValue::from_static("application/json"),
27707 )
27708 .headers(header_map)
27709 .build()?;
27710 let info = OperationInfo {
27711 operation_id: "specific_repeating_transaction",
27712 };
27713 self.pre(&mut request, &info).await?;
27714 let result = self.exec(request, &info).await;
27715 self.post(&result, &info).await?;
27716 let response = result?;
27717 match response.status().as_u16() {
27718 200u16 => ResponseValue::from_response(response).await,
27719 _ => Err(Error::UnexpectedResponse(response)),
27720 }
27721 }
27722
27723 ///List insights by transaction
27724 ///
27725 ///Use this endpoint to list all insights associated with a transaction
27726 /// GUID.
27727 ///
27728 ///Sends a `GET` request to
27729 /// `/users/{user_guid}/transactions/{transaction_guid}/insights`
27730 ///
27731 ///Arguments:
27732 /// - `user_guid`: The unique identifier for a `user`, beginning with the
27733 /// prefix `USR-`.
27734 /// - `transaction_guid`: The unique id for a `transaction`.
27735 /// - `page`: Results are paginated. Specify current page.
27736 /// - `records_per_page`: This specifies the number of records to be
27737 /// returned on each page. Defaults to `25`. The valid range is from `10`
27738 /// to `100`. If the value exceeds `100`, the default value of `25` will
27739 /// be used instead.
27740 pub async fn list_insights_by_transaction<'a>(
27741 &'a self,
27742 user_guid: &'a str,
27743 transaction_guid: &'a str,
27744 page: Option<i64>,
27745 records_per_page: Option<i64>,
27746 ) -> Result<ResponseValue<types::InsightsResponseBody>, Error<()>> {
27747 let url = format!(
27748 "{}/users/{}/transactions/{}/insights",
27749 self.baseurl,
27750 encode_path(&user_guid.to_string()),
27751 encode_path(&transaction_guid.to_string()),
27752 );
27753 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
27754 header_map.append(
27755 ::reqwest::header::HeaderName::from_static("api-version"),
27756 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
27757 );
27758 #[allow(unused_mut)]
27759 let mut request = self
27760 .client
27761 .get(url)
27762 .header(
27763 ::reqwest::header::ACCEPT,
27764 ::reqwest::header::HeaderValue::from_static("application/json"),
27765 )
27766 .query(&progenitor_client::QueryParam::new("page", &page))
27767 .query(&progenitor_client::QueryParam::new(
27768 "records_per_page",
27769 &records_per_page,
27770 ))
27771 .headers(header_map)
27772 .build()?;
27773 let info = OperationInfo {
27774 operation_id: "list_insights_by_transaction",
27775 };
27776 self.pre(&mut request, &info).await?;
27777 let result = self.exec(request, &info).await;
27778 self.post(&result, &info).await?;
27779 let response = result?;
27780 match response.status().as_u16() {
27781 200u16 => ResponseValue::from_response(response).await,
27782 _ => Err(Error::UnexpectedResponse(response)),
27783 }
27784 }
27785
27786 ///Create split transactions
27787 ///
27788 ///This endpoint creates two or more child transactions that are branched
27789 /// from a previous transaction. This endpoint allows you to link multiple
27790 /// categories, descriptions, and amounts to a parent transaction. When a
27791 /// split transaction is created, the parent transaction's `has_been_split`
27792 /// field will automatically be updated to true and the child transactions'
27793 /// `parent_guid` will have the transaction guid of the parent. The total
27794 /// amount of the child transactions must equal the amount of the parent
27795 /// transaction. Once a transaction has been split it can't be split again.
27796 /// In order to re-split a transaction, it must first be un-split. This can
27797 /// be done by calling the Delete Split Transactions endpoint. Calling this
27798 /// endpoint will delete the existing child transactions and update the
27799 /// parent transaction's `has_been_split` field to false. You can then
27800 /// re-split the parent transaction by calling Create Split Transaction
27801 /// again.
27802 ///
27803 ///
27804 ///Sends a `POST` request to
27805 /// `/users/{user_guid}/transactions/{transaction_guid}/split`
27806 ///
27807 ///Arguments:
27808 /// - `user_guid`: The unique identifier for a `user`, beginning with the
27809 /// prefix `USR-`.
27810 /// - `transaction_guid`: The unique id for a `transaction`.
27811 /// - `body`
27812 pub async fn create_split_transactions<'a>(
27813 &'a self,
27814 user_guid: &'a str,
27815 transaction_guid: &'a str,
27816 body: &'a types::SplitTransactionRequestBody,
27817 ) -> Result<ResponseValue<types::SplitTransactionsResponseBody>, Error<()>> {
27818 let url = format!(
27819 "{}/users/{}/transactions/{}/split",
27820 self.baseurl,
27821 encode_path(&user_guid.to_string()),
27822 encode_path(&transaction_guid.to_string()),
27823 );
27824 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
27825 header_map.append(
27826 ::reqwest::header::HeaderName::from_static("api-version"),
27827 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
27828 );
27829 #[allow(unused_mut)]
27830 let mut request = self
27831 .client
27832 .post(url)
27833 .header(
27834 ::reqwest::header::ACCEPT,
27835 ::reqwest::header::HeaderValue::from_static("application/json"),
27836 )
27837 .json(&body)
27838 .headers(header_map)
27839 .build()?;
27840 let info = OperationInfo {
27841 operation_id: "create_split_transactions",
27842 };
27843 self.pre(&mut request, &info).await?;
27844 let result = self.exec(request, &info).await;
27845 self.post(&result, &info).await?;
27846 let response = result?;
27847 match response.status().as_u16() {
27848 200u16 => ResponseValue::from_response(response).await,
27849 _ => Err(Error::UnexpectedResponse(response)),
27850 }
27851 }
27852
27853 ///Delete split transactions
27854 ///
27855 ///This endpoint deletes all split transactions linked to a parent
27856 /// transaction, but it leaves the parent transaction active. This request
27857 /// will also update the parent transaction's has_been_split field to false.
27858 /// This endpoint accepts the optional MX-Skip-Webhook header.
27859 ///
27860 ///Sends a `DELETE` request to
27861 /// `/users/{user_guid}/transactions/{transaction_guid}/split`
27862 ///
27863 ///Arguments:
27864 /// - `user_guid`: The unique identifier for a `user`, beginning with the
27865 /// prefix `USR-`.
27866 /// - `transaction_guid`: The unique id for a `transaction`.
27867 pub async fn delete_split_transactions<'a>(
27868 &'a self,
27869 user_guid: &'a str,
27870 transaction_guid: &'a str,
27871 ) -> Result<ResponseValue<()>, Error<()>> {
27872 let url = format!(
27873 "{}/users/{}/transactions/{}/split",
27874 self.baseurl,
27875 encode_path(&user_guid.to_string()),
27876 encode_path(&transaction_guid.to_string()),
27877 );
27878 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
27879 header_map.append(
27880 ::reqwest::header::HeaderName::from_static("api-version"),
27881 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
27882 );
27883 #[allow(unused_mut)]
27884 let mut request = self.client.delete(url).headers(header_map).build()?;
27885 let info = OperationInfo {
27886 operation_id: "delete_split_transactions",
27887 };
27888 self.pre(&mut request, &info).await?;
27889 let result = self.exec(request, &info).await;
27890 self.post(&result, &info).await?;
27891 let response = result?;
27892 match response.status().as_u16() {
27893 204u16 => Ok(ResponseValue::empty(response)),
27894 _ => Err(Error::UnexpectedResponse(response)),
27895 }
27896 }
27897
27898 ///Read monthly cash flow profile
27899 ///
27900 ///Read monthly cash flow profile.
27901 ///
27902 ///Sends a `GET` request to `/users/{user_guid}/monthly_cash_flow_profile`
27903 ///
27904 ///Arguments:
27905 /// - `user_guid`: The unique identifier for a `user`, beginning with the
27906 /// prefix `USR-`.
27907 pub async fn read_monthly_cash_flow_profile<'a>(
27908 &'a self,
27909 user_guid: &'a str,
27910 ) -> Result<ResponseValue<types::MonthlyCashFlowResponseBody>, Error<()>> {
27911 let url = format!(
27912 "{}/users/{}/monthly_cash_flow_profile",
27913 self.baseurl,
27914 encode_path(&user_guid.to_string()),
27915 );
27916 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
27917 header_map.append(
27918 ::reqwest::header::HeaderName::from_static("api-version"),
27919 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
27920 );
27921 #[allow(unused_mut)]
27922 let mut request = self
27923 .client
27924 .get(url)
27925 .header(
27926 ::reqwest::header::ACCEPT,
27927 ::reqwest::header::HeaderValue::from_static("application/json"),
27928 )
27929 .headers(header_map)
27930 .build()?;
27931 let info = OperationInfo {
27932 operation_id: "read_monthly_cash_flow_profile",
27933 };
27934 self.pre(&mut request, &info).await?;
27935 let result = self.exec(request, &info).await;
27936 self.post(&result, &info).await?;
27937 let response = result?;
27938 match response.status().as_u16() {
27939 200u16 => ResponseValue::from_response(response).await,
27940 _ => Err(Error::UnexpectedResponse(response)),
27941 }
27942 }
27943
27944 ///Update monthly cash flow profile
27945 ///
27946 ///Use this endpoint to update the attributes of a
27947 /// `monthly_cash_flow_profile`.
27948 ///
27949 ///Sends a `PUT` request to `/users/{user_guid}/monthly_cash_flow_profile`
27950 ///
27951 ///Arguments:
27952 /// - `user_guid`: The unique identifier for a `user`, beginning with the
27953 /// prefix `USR-`.
27954 /// - `body`
27955 pub async fn update_monthly_cash_flow_profile<'a>(
27956 &'a self,
27957 user_guid: &'a str,
27958 body: &'a types::MonthlyCashFlowProfileRequestBody,
27959 ) -> Result<ResponseValue<types::MonthlyCashFlowResponseBody>, Error<()>> {
27960 let url = format!(
27961 "{}/users/{}/monthly_cash_flow_profile",
27962 self.baseurl,
27963 encode_path(&user_guid.to_string()),
27964 );
27965 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
27966 header_map.append(
27967 ::reqwest::header::HeaderName::from_static("api-version"),
27968 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
27969 );
27970 #[allow(unused_mut)]
27971 let mut request = self
27972 .client
27973 .put(url)
27974 .header(
27975 ::reqwest::header::ACCEPT,
27976 ::reqwest::header::HeaderValue::from_static("application/json"),
27977 )
27978 .json(&body)
27979 .headers(header_map)
27980 .build()?;
27981 let info = OperationInfo {
27982 operation_id: "update_monthly_cash_flow_profile",
27983 };
27984 self.pre(&mut request, &info).await?;
27985 let result = self.exec(request, &info).await;
27986 self.post(&result, &info).await?;
27987 let response = result?;
27988 match response.status().as_u16() {
27989 200u16 => ResponseValue::from_response(response).await,
27990 _ => Err(Error::UnexpectedResponse(response)),
27991 }
27992 }
27993
27994 ///View a List of Tokens
27995 ///
27996 ///View a list of tokens that exist for a user, member, or account.
27997 ///
27998 ///Sends a `GET` request to `/tokens`
27999 pub async fn list_tokens<'a>(
28000 &'a self,
28001 body: &'a types::TokenRequestBody,
28002 ) -> Result<ResponseValue<types::TokenResponseBody>, Error<()>> {
28003 let url = format!("{}/tokens", self.baseurl,);
28004 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
28005 header_map.append(
28006 ::reqwest::header::HeaderName::from_static("api-version"),
28007 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
28008 );
28009 #[allow(unused_mut)]
28010 let mut request = self
28011 .client
28012 .get(url)
28013 .header(
28014 ::reqwest::header::ACCEPT,
28015 ::reqwest::header::HeaderValue::from_static("application/json"),
28016 )
28017 .json(&body)
28018 .headers(header_map)
28019 .build()?;
28020 let info = OperationInfo {
28021 operation_id: "list_tokens",
28022 };
28023 self.pre(&mut request, &info).await?;
28024 let result = self.exec(request, &info).await;
28025 self.post(&result, &info).await?;
28026 let response = result?;
28027 match response.status().as_u16() {
28028 200u16 => ResponseValue::from_response(response).await,
28029 _ => Err(Error::UnexpectedResponse(response)),
28030 }
28031 }
28032
28033 ///Request an account number (Processors Only)
28034 ///
28035 ///Get account information such as routing number and account number,
28036 /// scoped to your access token.
28037 ///
28038 ///Sends a `GET` request to `/account/account_numbers`
28039 pub async fn request_account_number<'a>(
28040 &'a self,
28041 ) -> Result<ResponseValue<types::ProcessorAccountNumberBody>, Error<()>> {
28042 let url = format!("{}/account/account_numbers", self.baseurl,);
28043 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
28044 header_map.append(
28045 ::reqwest::header::HeaderName::from_static("api-version"),
28046 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
28047 );
28048 #[allow(unused_mut)]
28049 let mut request = self
28050 .client
28051 .get(url)
28052 .header(
28053 ::reqwest::header::ACCEPT,
28054 ::reqwest::header::HeaderValue::from_static("application/json"),
28055 )
28056 .headers(header_map)
28057 .build()?;
28058 let info = OperationInfo {
28059 operation_id: "request_account_number",
28060 };
28061 self.pre(&mut request, &info).await?;
28062 let result = self.exec(request, &info).await;
28063 self.post(&result, &info).await?;
28064 let response = result?;
28065 match response.status().as_u16() {
28066 200u16 => ResponseValue::from_response(response).await,
28067 _ => Err(Error::UnexpectedResponse(response)),
28068 }
28069 }
28070
28071 ///Check Real Time Account Balance (Processors Only)
28072 ///
28073 ///Check the real-time account balance using your access token.
28074 ///
28075 ///Sends a `POST` request to `/account/check_balance`
28076 pub async fn check_real_time_account_balance<'a>(
28077 &'a self,
28078 ) -> Result<ResponseValue<types::MemberResponseBody>, Error<()>> {
28079 let url = format!("{}/account/check_balance", self.baseurl,);
28080 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
28081 header_map.append(
28082 ::reqwest::header::HeaderName::from_static("api-version"),
28083 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
28084 );
28085 #[allow(unused_mut)]
28086 let mut request = self
28087 .client
28088 .post(url)
28089 .header(
28090 ::reqwest::header::ACCEPT,
28091 ::reqwest::header::HeaderValue::from_static("application/json"),
28092 )
28093 .headers(header_map)
28094 .build()?;
28095 let info = OperationInfo {
28096 operation_id: "check_real_time_account_balance",
28097 };
28098 self.pre(&mut request, &info).await?;
28099 let result = self.exec(request, &info).await;
28100 self.post(&result, &info).await?;
28101 let response = result?;
28102 match response.status().as_u16() {
28103 200u16 => ResponseValue::from_response(response).await,
28104 _ => Err(Error::UnexpectedResponse(response)),
28105 }
28106 }
28107
28108 ///Read the account balance (Processors Only)
28109 ///
28110 ///Read the account balance (Processors Only)
28111 ///
28112 ///Sends a `GET` request to `/payment_account`
28113 pub async fn read_account_balance<'a>(
28114 &'a self,
28115 ) -> Result<ResponseValue<types::PaymentAccountBody>, Error<()>> {
28116 let url = format!("{}/payment_account", self.baseurl,);
28117 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
28118 header_map.append(
28119 ::reqwest::header::HeaderName::from_static("api-version"),
28120 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
28121 );
28122 #[allow(unused_mut)]
28123 let mut request = self
28124 .client
28125 .get(url)
28126 .header(
28127 ::reqwest::header::ACCEPT,
28128 ::reqwest::header::HeaderValue::from_static("application/json"),
28129 )
28130 .headers(header_map)
28131 .build()?;
28132 let info = OperationInfo {
28133 operation_id: "read_account_balance",
28134 };
28135 self.pre(&mut request, &info).await?;
28136 let result = self.exec(request, &info).await;
28137 self.post(&result, &info).await?;
28138 let response = result?;
28139 match response.status().as_u16() {
28140 200u16 => ResponseValue::from_response(response).await,
28141 _ => Err(Error::UnexpectedResponse(response)),
28142 }
28143 }
28144
28145 ///Get account owner information (Processors Only)
28146 ///
28147 ///Get account owner information (Processors Only)
28148 ///
28149 ///Sends a `GET` request to `/account/transactions`
28150 pub async fn get_account_owner_info<'a>(
28151 &'a self,
28152 ) -> Result<ResponseValue<types::ProcessorOwnerBody>, Error<()>> {
28153 let url = format!("{}/account/transactions", self.baseurl,);
28154 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
28155 header_map.append(
28156 ::reqwest::header::HeaderName::from_static("api-version"),
28157 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
28158 );
28159 #[allow(unused_mut)]
28160 let mut request = self
28161 .client
28162 .get(url)
28163 .header(
28164 ::reqwest::header::ACCEPT,
28165 ::reqwest::header::HeaderValue::from_static("application/json"),
28166 )
28167 .headers(header_map)
28168 .build()?;
28169 let info = OperationInfo {
28170 operation_id: "get_account_owner_info",
28171 };
28172 self.pre(&mut request, &info).await?;
28173 let result = self.exec(request, &info).await;
28174 self.post(&result, &info).await?;
28175 let response = result?;
28176 match response.status().as_u16() {
28177 200u16 => ResponseValue::from_response(response).await,
28178 _ => Err(Error::UnexpectedResponse(response)),
28179 }
28180 }
28181
28182 ///List all microdeposits for a user
28183 ///
28184 ///Use this endpoint to read the attributes of a specific microdeposit
28185 /// according to its unique GUID.
28186 ///
28187 ///Sends a `GET` request to `/users/{user_guid}/micro_deposits`
28188 ///
28189 ///Arguments:
28190 /// - `user_guid`: The unique identifier for a `user`, beginning with the
28191 /// prefix `USR-`.
28192 pub async fn list_user_microdeposits<'a>(
28193 &'a self,
28194 user_guid: &'a str,
28195 ) -> Result<ResponseValue<types::MicrodepositsResponseBody>, Error<()>> {
28196 let url = format!(
28197 "{}/users/{}/micro_deposits",
28198 self.baseurl,
28199 encode_path(&user_guid.to_string()),
28200 );
28201 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
28202 header_map.append(
28203 ::reqwest::header::HeaderName::from_static("api-version"),
28204 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
28205 );
28206 #[allow(unused_mut)]
28207 let mut request = self
28208 .client
28209 .get(url)
28210 .header(
28211 ::reqwest::header::ACCEPT,
28212 ::reqwest::header::HeaderValue::from_static("application/json"),
28213 )
28214 .headers(header_map)
28215 .build()?;
28216 let info = OperationInfo {
28217 operation_id: "list_user_microdeposits",
28218 };
28219 self.pre(&mut request, &info).await?;
28220 let result = self.exec(request, &info).await;
28221 self.post(&result, &info).await?;
28222 let response = result?;
28223 match response.status().as_u16() {
28224 200u16 => ResponseValue::from_response(response).await,
28225 _ => Err(Error::UnexpectedResponse(response)),
28226 }
28227 }
28228
28229 ///Create or pre-initiate a microdeposit
28230 ///
28231 ///Use this endpoint to create or pre-initiate a microdeposit. The response
28232 /// will include the new microdeposit record with a status of `INITIATED` or
28233 /// `PREINITIATED` respectively.
28234 ///
28235 ///To pre-initiate a microdeposit, you only need to set `email` (string),
28236 /// `first_name` (string), and `last_name` (string) in the request body.
28237 ///
28238 ///Pre-initiating a microdeposit allows you to pass the end user's first
28239 /// name, last name, and email if this data has already been collected. If
28240 /// the end user selects an institution which requires the microdeposit
28241 /// flow, the pre-initiated `micro_deposit` will be used and the Connect
28242 /// Widget step that normally requests this info from the end user will be
28243 /// skipped. However, if the end user selects an institution which supports
28244 /// IAV, the pre-initiated `micro_deposit` will be deleted and IAV will be
28245 /// used instead. When requesting a Connect Widget URL after pre-initiating,
28246 /// make sure to set the `current_microdeposit_guid` to the resulting
28247 /// microdeposit's `guid` and set the `mode` to `verification`. If you use
28248 /// this enhanced flow, a `micro_deposit` should be pre-initiated for all
28249 /// connect sessions in verification mode. After pre-initiating a
28250 /// microdeposit, pass the GUID to the config as `current_microdeposit_guid`
28251 /// and set the `mode` to `verification` when requesting a Connect URL.
28252 /// Pre-initiating a microdeposit is optional. If you choose to implement
28253 /// this flow, it should be used for all Connect Widget sessions in
28254 /// verification mode.
28255 ///
28256 ///
28257 ///Sends a `POST` request to `/users/{user_guid}/micro_deposits`
28258 ///
28259 ///Arguments:
28260 /// - `user_guid`: The unique identifier for a `user`, beginning with the
28261 /// prefix `USR-`.
28262 /// - `body`
28263 pub async fn create_microdeposit<'a>(
28264 &'a self,
28265 user_guid: &'a str,
28266 body: &'a types::MicrodepositRequestBody,
28267 ) -> Result<ResponseValue<types::MicrodepositResponseBody>, Error<()>> {
28268 let url = format!(
28269 "{}/users/{}/micro_deposits",
28270 self.baseurl,
28271 encode_path(&user_guid.to_string()),
28272 );
28273 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
28274 header_map.append(
28275 ::reqwest::header::HeaderName::from_static("api-version"),
28276 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
28277 );
28278 #[allow(unused_mut)]
28279 let mut request = self
28280 .client
28281 .post(url)
28282 .header(
28283 ::reqwest::header::ACCEPT,
28284 ::reqwest::header::HeaderValue::from_static("application/json"),
28285 )
28286 .json(&body)
28287 .headers(header_map)
28288 .build()?;
28289 let info = OperationInfo {
28290 operation_id: "create_microdeposit",
28291 };
28292 self.pre(&mut request, &info).await?;
28293 let result = self.exec(request, &info).await;
28294 self.post(&result, &info).await?;
28295 let response = result?;
28296 match response.status().as_u16() {
28297 200u16 => ResponseValue::from_response(response).await,
28298 _ => Err(Error::UnexpectedResponse(response)),
28299 }
28300 }
28301
28302 ///Read a microdeposit for a user
28303 ///
28304 ///Use this endpoint to read the attributes of a specific microdeposit
28305 /// according to its unique GUID. <br /><br /> Webhooks for microdeposit
28306 /// status changes are triggered when a status changes. The actual status of
28307 /// the microdeposit guid updates every minute. You may force a status
28308 /// update by calling the read microdeposit endpoint.
28309 ///
28310 ///Sends a `GET` request to
28311 /// `/users/{user_guid}/micro_deposits/{micro_deposit_guid}`
28312 ///
28313 ///Arguments:
28314 /// - `user_guid`: The unique identifier for a `user`, beginning with the
28315 /// prefix `USR-`.
28316 /// - `micro_deposit_guid`: The unique identifier for the microdeposit.
28317 /// Defined by MX.
28318 pub async fn read_user_microdeposit<'a>(
28319 &'a self,
28320 user_guid: &'a str,
28321 micro_deposit_guid: &'a str,
28322 ) -> Result<ResponseValue<types::MicrodepositResponseBody>, Error<()>> {
28323 let url = format!(
28324 "{}/users/{}/micro_deposits/{}",
28325 self.baseurl,
28326 encode_path(&user_guid.to_string()),
28327 encode_path(µ_deposit_guid.to_string()),
28328 );
28329 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
28330 header_map.append(
28331 ::reqwest::header::HeaderName::from_static("api-version"),
28332 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
28333 );
28334 #[allow(unused_mut)]
28335 let mut request = self
28336 .client
28337 .get(url)
28338 .header(
28339 ::reqwest::header::ACCEPT,
28340 ::reqwest::header::HeaderValue::from_static("application/json"),
28341 )
28342 .headers(header_map)
28343 .build()?;
28344 let info = OperationInfo {
28345 operation_id: "read_user_microdeposit",
28346 };
28347 self.pre(&mut request, &info).await?;
28348 let result = self.exec(request, &info).await;
28349 self.post(&result, &info).await?;
28350 let response = result?;
28351 match response.status().as_u16() {
28352 200u16 => ResponseValue::from_response(response).await,
28353 _ => Err(Error::UnexpectedResponse(response)),
28354 }
28355 }
28356
28357 ///Delete a microdeposit
28358 ///
28359 ///Use this endpoint to delete the specified microdeposit.
28360 ///
28361 ///Sends a `DELETE` request to
28362 /// `/users/{user_guid}/micro_deposits/{micro_deposit_guid}`
28363 ///
28364 ///Arguments:
28365 /// - `user_guid`: The unique identifier for a `user`, beginning with the
28366 /// prefix `USR-`.
28367 /// - `micro_deposit_guid`: The unique identifier for the microdeposit.
28368 /// Defined by MX.
28369 pub async fn delete_microdeposit<'a>(
28370 &'a self,
28371 user_guid: &'a str,
28372 micro_deposit_guid: &'a str,
28373 ) -> Result<ResponseValue<()>, Error<()>> {
28374 let url = format!(
28375 "{}/users/{}/micro_deposits/{}",
28376 self.baseurl,
28377 encode_path(&user_guid.to_string()),
28378 encode_path(µ_deposit_guid.to_string()),
28379 );
28380 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
28381 header_map.append(
28382 ::reqwest::header::HeaderName::from_static("api-version"),
28383 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
28384 );
28385 #[allow(unused_mut)]
28386 let mut request = self.client.delete(url).headers(header_map).build()?;
28387 let info = OperationInfo {
28388 operation_id: "delete_microdeposit",
28389 };
28390 self.pre(&mut request, &info).await?;
28391 let result = self.exec(request, &info).await;
28392 self.post(&result, &info).await?;
28393 let response = result?;
28394 match response.status().as_u16() {
28395 204u16 => Ok(ResponseValue::empty(response)),
28396 _ => Err(Error::UnexpectedResponse(response)),
28397 }
28398 }
28399
28400 ///Verify a Microdeposit
28401 ///
28402 ///Use this endpoint to verify the amounts deposited into the account
28403 /// during a microdeposit verification. The verification has not
28404 /// successfully completed until the `status` is `VERIFIED`. Poll the
28405 /// `/users/{user_guid}/micro_deposits/{micro_deposit_guid}` (read
28406 /// microdeposit) endpoint until you see this status or an error state.
28407 ///
28408 ///Sends a `PUT` request to `/micro_deposits/{micro_deposit_guid}/verify`
28409 ///
28410 ///Arguments:
28411 /// - `micro_deposit_guid`: The unique identifier for the microdeposit.
28412 /// Defined by MX.
28413 /// - `body`
28414 pub async fn verify_microdeposit<'a>(
28415 &'a self,
28416 micro_deposit_guid: &'a str,
28417 body: &'a types::MicrodepositVerifyRequestBody,
28418 ) -> Result<ResponseValue<types::MicrodepositResponseBody>, Error<()>> {
28419 let url = format!(
28420 "{}/micro_deposits/{}/verify",
28421 self.baseurl,
28422 encode_path(µ_deposit_guid.to_string()),
28423 );
28424 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
28425 header_map.append(
28426 ::reqwest::header::HeaderName::from_static("api-version"),
28427 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
28428 );
28429 #[allow(unused_mut)]
28430 let mut request = self
28431 .client
28432 .put(url)
28433 .header(
28434 ::reqwest::header::ACCEPT,
28435 ::reqwest::header::HeaderValue::from_static("application/json"),
28436 )
28437 .json(&body)
28438 .headers(header_map)
28439 .build()?;
28440 let info = OperationInfo {
28441 operation_id: "verify_microdeposit",
28442 };
28443 self.pre(&mut request, &info).await?;
28444 let result = self.exec(request, &info).await;
28445 self.post(&result, &info).await?;
28446 let response = result?;
28447 match response.status().as_u16() {
28448 200u16 => ResponseValue::from_response(response).await,
28449 _ => Err(Error::UnexpectedResponse(response)),
28450 }
28451 }
28452
28453 ///List all verifications for a user
28454 ///
28455 ///This endpoint returns a list of the account verifications associated
28456 /// with the user, as well as the status of those verifications.
28457 ///
28458 ///
28459 ///Sends a `GET` request to `/users/{user_guid}/account_verifications`
28460 ///
28461 ///Arguments:
28462 /// - `user_guid`: The unique identifier for a `user`, beginning with the
28463 /// prefix `USR-`.
28464 pub async fn list_user_verifications<'a>(
28465 &'a self,
28466 user_guid: &'a str,
28467 ) -> Result<ResponseValue<types::MicrodepositResponseBody>, Error<()>> {
28468 let url = format!(
28469 "{}/users/{}/account_verifications",
28470 self.baseurl,
28471 encode_path(&user_guid.to_string()),
28472 );
28473 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
28474 header_map.append(
28475 ::reqwest::header::HeaderName::from_static("api-version"),
28476 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
28477 );
28478 #[allow(unused_mut)]
28479 let mut request = self
28480 .client
28481 .get(url)
28482 .header(
28483 ::reqwest::header::ACCEPT,
28484 ::reqwest::header::HeaderValue::from_static("application/json"),
28485 )
28486 .headers(header_map)
28487 .build()?;
28488 let info = OperationInfo {
28489 operation_id: "list_user_verifications",
28490 };
28491 self.pre(&mut request, &info).await?;
28492 let result = self.exec(request, &info).await;
28493 self.post(&result, &info).await?;
28494 let response = result?;
28495 match response.status().as_u16() {
28496 200u16 => ResponseValue::from_response(response).await,
28497 _ => Err(Error::UnexpectedResponse(response)),
28498 }
28499 }
28500
28501 ///Fetch Rewards
28502 ///
28503 ///Calling this endpoint initiates an aggregation-type event which will
28504 /// gather the member's rewards information, as well as account and
28505 /// transaction information. Rewards data is also gathered with daily
28506 /// background aggregations. Member and Rewards guids are defined by MX.
28507 ///
28508 ///Sends a `POST` request to
28509 /// `/users/{user_guid}/members/{member_guid}/fetch_rewards`
28510 ///
28511 ///Arguments:
28512 /// - `user_guid`: The unique identifier for a `user`, beginning with the
28513 /// prefix `USR-`.
28514 /// - `member_guid`: The unique id for a `member`.
28515 pub async fn fetch_rewards<'a>(
28516 &'a self,
28517 user_guid: &'a str,
28518 member_guid: &'a str,
28519 ) -> Result<ResponseValue<types::MemberResponseBody>, Error<()>> {
28520 let url = format!(
28521 "{}/users/{}/members/{}/fetch_rewards",
28522 self.baseurl,
28523 encode_path(&user_guid.to_string()),
28524 encode_path(&member_guid.to_string()),
28525 );
28526 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
28527 header_map.append(
28528 ::reqwest::header::HeaderName::from_static("api-version"),
28529 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
28530 );
28531 #[allow(unused_mut)]
28532 let mut request = self
28533 .client
28534 .post(url)
28535 .header(
28536 ::reqwest::header::ACCEPT,
28537 ::reqwest::header::HeaderValue::from_static("application/json"),
28538 )
28539 .headers(header_map)
28540 .build()?;
28541 let info = OperationInfo {
28542 operation_id: "fetch_rewards",
28543 };
28544 self.pre(&mut request, &info).await?;
28545 let result = self.exec(request, &info).await;
28546 self.post(&result, &info).await?;
28547 let response = result?;
28548 match response.status().as_u16() {
28549 200u16 => ResponseValue::from_response(response).await,
28550 _ => Err(Error::UnexpectedResponse(response)),
28551 }
28552 }
28553
28554 ///List Rewards
28555 ///
28556 ///Use this endpoint to list all the `rewards` associated with a specified
28557 /// `member`. Member guids are defined by MX.
28558 ///
28559 ///Sends a `GET` request to
28560 /// `/users/{user_guid}/members/{member_guid}/rewards`
28561 ///
28562 ///Arguments:
28563 /// - `user_guid`: The unique identifier for a `user`, beginning with the
28564 /// prefix `USR-`.
28565 /// - `member_guid`: The unique id for a `member`.
28566 pub async fn list_rewards<'a>(
28567 &'a self,
28568 user_guid: &'a str,
28569 member_guid: &'a str,
28570 ) -> Result<ResponseValue<types::RewardsResponseBody>, Error<()>> {
28571 let url = format!(
28572 "{}/users/{}/members/{}/rewards",
28573 self.baseurl,
28574 encode_path(&user_guid.to_string()),
28575 encode_path(&member_guid.to_string()),
28576 );
28577 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
28578 header_map.append(
28579 ::reqwest::header::HeaderName::from_static("api-version"),
28580 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
28581 );
28582 #[allow(unused_mut)]
28583 let mut request = self
28584 .client
28585 .get(url)
28586 .header(
28587 ::reqwest::header::ACCEPT,
28588 ::reqwest::header::HeaderValue::from_static("application/json"),
28589 )
28590 .headers(header_map)
28591 .build()?;
28592 let info = OperationInfo {
28593 operation_id: "list_rewards",
28594 };
28595 self.pre(&mut request, &info).await?;
28596 let result = self.exec(request, &info).await;
28597 self.post(&result, &info).await?;
28598 let response = result?;
28599 match response.status().as_u16() {
28600 200u16 => ResponseValue::from_response(response).await,
28601 _ => Err(Error::UnexpectedResponse(response)),
28602 }
28603 }
28604
28605 ///Read Reward
28606 ///
28607 ///Use this endpoint to read a specific `reward` based on its unique GUID.
28608 /// Member and Rewards guids are defined by MX.
28609 ///
28610 ///Sends a `GET` request to
28611 /// `/users/{user_guid}/members/{member_guid}/rewards/{reward_guid}`
28612 ///
28613 ///Arguments:
28614 /// - `user_guid`: The unique identifier for a `user`, beginning with the
28615 /// prefix `USR-`.
28616 /// - `member_guid`: The unique id for a `member`.
28617 /// - `reward_guid`: The unique identifier for the rewards. Defined by MX.
28618 pub async fn read_rewards<'a>(
28619 &'a self,
28620 user_guid: &'a str,
28621 member_guid: &'a str,
28622 reward_guid: &'a str,
28623 ) -> Result<ResponseValue<types::RewardResponseBody>, Error<()>> {
28624 let url = format!(
28625 "{}/users/{}/members/{}/rewards/{}",
28626 self.baseurl,
28627 encode_path(&user_guid.to_string()),
28628 encode_path(&member_guid.to_string()),
28629 encode_path(&reward_guid.to_string()),
28630 );
28631 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
28632 header_map.append(
28633 ::reqwest::header::HeaderName::from_static("api-version"),
28634 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
28635 );
28636 #[allow(unused_mut)]
28637 let mut request = self
28638 .client
28639 .get(url)
28640 .header(
28641 ::reqwest::header::ACCEPT,
28642 ::reqwest::header::HeaderValue::from_static("application/json"),
28643 )
28644 .headers(header_map)
28645 .build()?;
28646 let info = OperationInfo {
28647 operation_id: "read_rewards",
28648 };
28649 self.pre(&mut request, &info).await?;
28650 let result = self.exec(request, &info).await;
28651 self.post(&result, &info).await?;
28652 let response = result?;
28653 match response.status().as_u16() {
28654 200u16 => ResponseValue::from_response(response).await,
28655 _ => Err(Error::UnexpectedResponse(response)),
28656 }
28657 }
28658
28659 ///Read a Credit Card Product
28660 ///
28661 ///This endpoint returns the specified `credit_card_product` according to
28662 /// the unique GUID.
28663 ///
28664 ///Sends a `GET` request to
28665 /// `/credit_card_products/{credit_card_product_guid}`
28666 ///
28667 ///Arguments:
28668 /// - `credit_card_product_guid`: The required `credit_card_product_guid`
28669 /// can be found on the `account` object.
28670 pub async fn credit_card<'a>(
28671 &'a self,
28672 credit_card_product_guid: &'a str,
28673 ) -> Result<ResponseValue<types::CreditCardProductResponse>, Error<()>> {
28674 let url = format!(
28675 "{}/credit_card_products/{}",
28676 self.baseurl,
28677 encode_path(&credit_card_product_guid.to_string()),
28678 );
28679 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
28680 header_map.append(
28681 ::reqwest::header::HeaderName::from_static("api-version"),
28682 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
28683 );
28684 #[allow(unused_mut)]
28685 let mut request = self
28686 .client
28687 .get(url)
28688 .header(
28689 ::reqwest::header::ACCEPT,
28690 ::reqwest::header::HeaderValue::from_static("application/json"),
28691 )
28692 .headers(header_map)
28693 .build()?;
28694 let info = OperationInfo {
28695 operation_id: "credit_card",
28696 };
28697 self.pre(&mut request, &info).await?;
28698 let result = self.exec(request, &info).await;
28699 self.post(&result, &info).await?;
28700 let response = result?;
28701 match response.status().as_u16() {
28702 200u16 => ResponseValue::from_response(response).await,
28703 _ => Err(Error::UnexpectedResponse(response)),
28704 }
28705 }
28706
28707 ///Get Identity Data
28708 ///
28709 ///Get an MX-issued verifiable credential of a user's identity data.
28710 ///
28711 ///Sends a `GET` request to
28712 /// `/vc/users/{user_guid}/members/{member_guid}/customers`
28713 ///
28714 ///Arguments:
28715 /// - `user_guid`: The unique identifier for a `user`, beginning with the
28716 /// prefix `USR-`.
28717 /// - `member_guid`: The unique id for a `member`.
28718 pub async fn get_identity_data<'a>(
28719 &'a self,
28720 user_guid: &'a str,
28721 member_guid: &'a str,
28722 ) -> Result<ResponseValue<ByteStream>, Error<()>> {
28723 let url = format!(
28724 "{}/vc/users/{}/members/{}/customers",
28725 self.baseurl,
28726 encode_path(&user_guid.to_string()),
28727 encode_path(&member_guid.to_string()),
28728 );
28729 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
28730 header_map.append(
28731 ::reqwest::header::HeaderName::from_static("api-version"),
28732 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
28733 );
28734 #[allow(unused_mut)]
28735 let mut request = self.client.get(url).headers(header_map).build()?;
28736 let info = OperationInfo {
28737 operation_id: "get_identity_data",
28738 };
28739 self.pre(&mut request, &info).await?;
28740 let result = self.exec(request, &info).await;
28741 self.post(&result, &info).await?;
28742 let response = result?;
28743 match response.status().as_u16() {
28744 200u16 => Ok(ResponseValue::stream(response)),
28745 _ => Err(Error::UnexpectedResponse(response)),
28746 }
28747 }
28748
28749 ///Get Accounts Data
28750 ///
28751 ///Get an MX-issued verifiable credential of a user's accounts data.
28752 ///
28753 ///Sends a `GET` request to
28754 /// `/vc/users/{user_guid}/members/{member_guid}/accounts`
28755 ///
28756 ///Arguments:
28757 /// - `user_guid`: The unique identifier for a `user`, beginning with the
28758 /// prefix `USR-`.
28759 /// - `member_guid`: The unique id for a `member`.
28760 pub async fn get_accounts_data<'a>(
28761 &'a self,
28762 user_guid: &'a str,
28763 member_guid: &'a str,
28764 ) -> Result<ResponseValue<ByteStream>, Error<()>> {
28765 let url = format!(
28766 "{}/vc/users/{}/members/{}/accounts",
28767 self.baseurl,
28768 encode_path(&user_guid.to_string()),
28769 encode_path(&member_guid.to_string()),
28770 );
28771 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
28772 header_map.append(
28773 ::reqwest::header::HeaderName::from_static("api-version"),
28774 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
28775 );
28776 #[allow(unused_mut)]
28777 let mut request = self.client.get(url).headers(header_map).build()?;
28778 let info = OperationInfo {
28779 operation_id: "get_accounts_data",
28780 };
28781 self.pre(&mut request, &info).await?;
28782 let result = self.exec(request, &info).await;
28783 self.post(&result, &info).await?;
28784 let response = result?;
28785 match response.status().as_u16() {
28786 200u16 => Ok(ResponseValue::stream(response)),
28787 _ => Err(Error::UnexpectedResponse(response)),
28788 }
28789 }
28790
28791 ///Get Transactions Data
28792 ///
28793 ///Get an MX-issued verifiable credential of a user's transaction data.
28794 ///
28795 ///Sends a `GET` request to
28796 /// `/vc/users/{user_guid}/accounts/{account_guid}/transactions`
28797 ///
28798 ///Arguments:
28799 /// - `user_guid`: The unique identifier for a `user`, beginning with the
28800 /// prefix `USR-`.
28801 /// - `account_guid`: The unique id for an `account`.
28802 /// - `end_time`: Filter transactions to this date. Must be in the format
28803 /// YYYY-MM-DD. The range is limited to 1 year.
28804 /// - `start_time`: Filter transactions from this date. Must be in the
28805 /// format YYYY-MM-DD. The range is limited to 1 year.
28806 pub async fn get_transactions_data<'a>(
28807 &'a self,
28808 user_guid: &'a str,
28809 account_guid: &'a str,
28810 end_time: Option<&'a str>,
28811 start_time: Option<&'a str>,
28812 ) -> Result<ResponseValue<ByteStream>, Error<()>> {
28813 let url = format!(
28814 "{}/vc/users/{}/accounts/{}/transactions",
28815 self.baseurl,
28816 encode_path(&user_guid.to_string()),
28817 encode_path(&account_guid.to_string()),
28818 );
28819 let mut header_map = ::reqwest::header::HeaderMap::with_capacity(1usize);
28820 header_map.append(
28821 ::reqwest::header::HeaderName::from_static("api-version"),
28822 ::reqwest::header::HeaderValue::from_static(Self::api_version()),
28823 );
28824 #[allow(unused_mut)]
28825 let mut request = self
28826 .client
28827 .get(url)
28828 .query(&progenitor_client::QueryParam::new("endTime", &end_time))
28829 .query(&progenitor_client::QueryParam::new(
28830 "startTime",
28831 &start_time,
28832 ))
28833 .headers(header_map)
28834 .build()?;
28835 let info = OperationInfo {
28836 operation_id: "get_transactions_data",
28837 };
28838 self.pre(&mut request, &info).await?;
28839 let result = self.exec(request, &info).await;
28840 self.post(&result, &info).await?;
28841 let response = result?;
28842 match response.status().as_u16() {
28843 200u16 => Ok(ResponseValue::stream(response)),
28844 _ => Err(Error::UnexpectedResponse(response)),
28845 }
28846 }
28847}
28848
28849/// Items consumers will typically use such as the Client.
28850pub mod prelude {
28851 #[allow(unused_imports)]
28852 pub use super::Client;
28853}