modern_treasury 0.6.0 → 0.7.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (86) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +41 -0
  3. data/README.md +9 -9
  4. data/lib/modern_treasury/errors.rb +25 -11
  5. data/lib/modern_treasury/file_part.rb +10 -7
  6. data/lib/modern_treasury/internal/page.rb +3 -3
  7. data/lib/modern_treasury/internal/transport/base_client.rb +11 -7
  8. data/lib/modern_treasury/internal/transport/pooled_net_requester.rb +7 -10
  9. data/lib/modern_treasury/internal/type/base_page.rb +1 -1
  10. data/lib/modern_treasury/internal/type/file_input.rb +7 -4
  11. data/lib/modern_treasury/internal/util.rb +5 -5
  12. data/lib/modern_treasury/models/bulk_request_create_params.rb +49 -2
  13. data/lib/modern_treasury/models/counterparty.rb +5 -18
  14. data/lib/modern_treasury/models/counterparty_create_params.rb +5 -16
  15. data/lib/modern_treasury/models/incoming_payment_detail.rb +23 -1
  16. data/lib/modern_treasury/models/internal_account.rb +25 -1
  17. data/lib/modern_treasury/models/internal_account_list_params.rb +23 -1
  18. data/lib/modern_treasury/models/invoice_list_params.rb +17 -1
  19. data/lib/modern_treasury/models/payment_order.rb +175 -1
  20. data/lib/modern_treasury/models/payment_order_create_async_params.rb +22 -1
  21. data/lib/modern_treasury/models/payment_order_create_params.rb +22 -1
  22. data/lib/modern_treasury/models/payment_order_list_params.rb +1 -0
  23. data/lib/modern_treasury/models/payment_order_update_params.rb +23 -1
  24. data/lib/modern_treasury/models/payment_orders/reversal.rb +24 -1
  25. data/lib/modern_treasury/models/payment_reference.rb +1 -0
  26. data/lib/modern_treasury/models/return_create_params.rb +21 -1
  27. data/lib/modern_treasury/models/return_object.rb +25 -1
  28. data/lib/modern_treasury/models/transaction.rb +1 -0
  29. data/lib/modern_treasury/resources/counterparties.rb +1 -1
  30. data/lib/modern_treasury/resources/internal_accounts.rb +3 -1
  31. data/lib/modern_treasury/resources/invoices.rb +5 -1
  32. data/lib/modern_treasury/resources/payment_orders.rb +9 -3
  33. data/lib/modern_treasury/resources/returns.rb +3 -1
  34. data/lib/modern_treasury/version.rb +1 -1
  35. data/rbi/modern_treasury/errors.rbi +29 -2
  36. data/rbi/modern_treasury/file_part.rbi +1 -1
  37. data/rbi/modern_treasury/internal/transport/base_client.rbi +4 -5
  38. data/rbi/modern_treasury/internal/type/base_page.rbi +1 -1
  39. data/rbi/modern_treasury/internal/util.rbi +1 -1
  40. data/rbi/modern_treasury/models/bulk_request_create_params.rbi +133 -0
  41. data/rbi/modern_treasury/models/counterparty.rbi +3 -49
  42. data/rbi/modern_treasury/models/counterparty_create_params.rbi +4 -62
  43. data/rbi/modern_treasury/models/incoming_payment_detail.rbi +54 -0
  44. data/rbi/modern_treasury/models/internal_account.rbi +52 -0
  45. data/rbi/modern_treasury/models/internal_account_list_params.rbi +66 -0
  46. data/rbi/modern_treasury/models/invoice_list_params.rbi +22 -0
  47. data/rbi/modern_treasury/models/payment_order.rbi +305 -0
  48. data/rbi/modern_treasury/models/payment_order_create_async_params.rbi +64 -0
  49. data/rbi/modern_treasury/models/payment_order_create_params.rbi +64 -0
  50. data/rbi/modern_treasury/models/payment_order_list_params.rbi +5 -0
  51. data/rbi/modern_treasury/models/payment_order_update_params.rbi +69 -0
  52. data/rbi/modern_treasury/models/payment_orders/reversal.rbi +54 -0
  53. data/rbi/modern_treasury/models/payment_reference.rbi +5 -0
  54. data/rbi/modern_treasury/models/return_create_params.rbi +64 -0
  55. data/rbi/modern_treasury/models/return_object.rbi +58 -0
  56. data/rbi/modern_treasury/models/transaction.rbi +5 -0
  57. data/rbi/modern_treasury/resources/counterparties.rbi +1 -2
  58. data/rbi/modern_treasury/resources/internal_accounts.rbi +3 -0
  59. data/rbi/modern_treasury/resources/invoices.rbi +6 -0
  60. data/rbi/modern_treasury/resources/payment_orders.rbi +12 -0
  61. data/rbi/modern_treasury/resources/returns.rbi +4 -0
  62. data/sig/modern_treasury/errors.rbs +7 -0
  63. data/sig/modern_treasury/file_part.rbs +1 -1
  64. data/sig/modern_treasury/models/bulk_request_create_params.rbs +46 -0
  65. data/sig/modern_treasury/models/counterparty.rbs +4 -18
  66. data/sig/modern_treasury/models/counterparty_create_params.rbs +5 -21
  67. data/sig/modern_treasury/models/incoming_payment_detail.rbs +18 -0
  68. data/sig/modern_treasury/models/internal_account.rbs +20 -0
  69. data/sig/modern_treasury/models/internal_account_list_params.rbs +25 -1
  70. data/sig/modern_treasury/models/invoice_list_params.rbs +14 -0
  71. data/sig/modern_treasury/models/payment_order.rbs +132 -0
  72. data/sig/modern_treasury/models/payment_order_create_async_params.rbs +22 -0
  73. data/sig/modern_treasury/models/payment_order_create_params.rbs +22 -0
  74. data/sig/modern_treasury/models/payment_order_list_params.rbs +2 -0
  75. data/sig/modern_treasury/models/payment_order_update_params.rbs +24 -0
  76. data/sig/modern_treasury/models/payment_orders/reversal.rbs +18 -0
  77. data/sig/modern_treasury/models/payment_reference.rbs +2 -0
  78. data/sig/modern_treasury/models/return_create_params.rbs +23 -1
  79. data/sig/modern_treasury/models/return_object.rbs +22 -0
  80. data/sig/modern_treasury/models/transaction.rbs +2 -0
  81. data/sig/modern_treasury/resources/counterparties.rbs +1 -1
  82. data/sig/modern_treasury/resources/internal_accounts.rbs +1 -0
  83. data/sig/modern_treasury/resources/invoices.rbs +2 -0
  84. data/sig/modern_treasury/resources/payment_orders.rbs +3 -0
  85. data/sig/modern_treasury/resources/returns.rbs +1 -0
  86. metadata +2 -2
@@ -58,6 +58,19 @@ module ModernTreasury
58
58
  sig { returns(ModernTreasury::Currency::TaggedSymbol) }
59
59
  attr_accessor :currency
60
60
 
61
+ # If the payment order's status is `held`, this will include the hold object's
62
+ # data.
63
+ sig { returns(T.nilable(ModernTreasury::PaymentOrder::CurrentHold)) }
64
+ attr_reader :current_hold
65
+
66
+ sig do
67
+ params(
68
+ current_hold:
69
+ T.nilable(ModernTreasury::PaymentOrder::CurrentHold::OrHash)
70
+ ).void
71
+ end
72
+ attr_writer :current_hold
73
+
61
74
  # If the payment order's status is `returned`, this will include the return
62
75
  # object's data.
63
76
  sig { returns(T.nilable(ModernTreasury::ReturnObject)) }
@@ -188,6 +201,14 @@ module ModernTreasury
188
201
  end
189
202
  attr_accessor :receiving_account_type
190
203
 
204
+ # One of `unreconciled`, `tentatively_reconciled` or `reconciled`.
205
+ sig do
206
+ returns(
207
+ ModernTreasury::PaymentOrder::ReconciliationStatus::TaggedSymbol
208
+ )
209
+ end
210
+ attr_accessor :reconciliation_status
211
+
191
212
  sig { returns(T::Array[ModernTreasury::PaymentOrder::ReferenceNumber]) }
192
213
  attr_accessor :reference_numbers
193
214
 
@@ -301,6 +322,8 @@ module ModernTreasury
301
322
  counterparty_id: T.nilable(String),
302
323
  created_at: Time,
303
324
  currency: ModernTreasury::Currency::OrSymbol,
325
+ current_hold:
326
+ T.nilable(ModernTreasury::PaymentOrder::CurrentHold::OrHash),
304
327
  current_return: T.nilable(ModernTreasury::ReturnObject::OrHash),
305
328
  description: T.nilable(String),
306
329
  direction: ModernTreasury::PaymentOrder::Direction::OrSymbol,
@@ -327,6 +350,8 @@ module ModernTreasury
327
350
  receiving_account_id: String,
328
351
  receiving_account_type:
329
352
  ModernTreasury::PaymentOrder::ReceivingAccountType::OrSymbol,
353
+ reconciliation_status:
354
+ ModernTreasury::PaymentOrder::ReconciliationStatus::OrSymbol,
330
355
  reference_numbers:
331
356
  T::Array[ModernTreasury::PaymentOrder::ReferenceNumber::OrHash],
332
357
  remittance_information: T.nilable(String),
@@ -379,6 +404,9 @@ module ModernTreasury
379
404
  created_at:,
380
405
  # Defaults to the currency of the originating account.
381
406
  currency:,
407
+ # If the payment order's status is `held`, this will include the hold object's
408
+ # data.
409
+ current_hold:,
382
410
  # If the payment order's status is `returned`, this will include the return
383
411
  # object's data.
384
412
  current_return:,
@@ -442,6 +470,8 @@ module ModernTreasury
442
470
  # The receiving account ID. Can be an `external_account` or `internal_account`.
443
471
  receiving_account_id:,
444
472
  receiving_account_type:,
473
+ # One of `unreconciled`, `tentatively_reconciled` or `reconciled`.
474
+ reconciliation_status:,
445
475
  reference_numbers:,
446
476
  # For `ach`, this field will be passed through on an addenda record. For `wire`
447
477
  # payments the field will be passed through as the "Originator to Beneficiary
@@ -511,6 +541,7 @@ module ModernTreasury
511
541
  counterparty_id: T.nilable(String),
512
542
  created_at: Time,
513
543
  currency: ModernTreasury::Currency::TaggedSymbol,
544
+ current_hold: T.nilable(ModernTreasury::PaymentOrder::CurrentHold),
514
545
  current_return: T.nilable(ModernTreasury::ReturnObject),
515
546
  description: T.nilable(String),
516
547
  direction: ModernTreasury::PaymentOrder::Direction::TaggedSymbol,
@@ -537,6 +568,8 @@ module ModernTreasury
537
568
  receiving_account_id: String,
538
569
  receiving_account_type:
539
570
  ModernTreasury::PaymentOrder::ReceivingAccountType::TaggedSymbol,
571
+ reconciliation_status:
572
+ ModernTreasury::PaymentOrder::ReconciliationStatus::TaggedSymbol,
540
573
  reference_numbers:
541
574
  T::Array[ModernTreasury::PaymentOrder::ReferenceNumber],
542
575
  remittance_information: T.nilable(String),
@@ -652,6 +685,235 @@ module ModernTreasury
652
685
  end
653
686
  end
654
687
 
688
+ class CurrentHold < ModernTreasury::Internal::Type::BaseModel
689
+ OrHash =
690
+ T.type_alias do
691
+ T.any(
692
+ ModernTreasury::PaymentOrder::CurrentHold,
693
+ ModernTreasury::Internal::AnyHash
694
+ )
695
+ end
696
+
697
+ sig { returns(String) }
698
+ attr_accessor :id
699
+
700
+ sig { returns(Time) }
701
+ attr_accessor :created_at
702
+
703
+ # The type of object
704
+ sig do
705
+ returns(
706
+ ModernTreasury::PaymentOrder::CurrentHold::Object::TaggedSymbol
707
+ )
708
+ end
709
+ attr_accessor :object
710
+
711
+ # The status of the hold
712
+ sig do
713
+ returns(
714
+ ModernTreasury::PaymentOrder::CurrentHold::Status::TaggedSymbol
715
+ )
716
+ end
717
+ attr_accessor :status
718
+
719
+ # The ID of the target being held
720
+ sig { returns(String) }
721
+ attr_accessor :target_id
722
+
723
+ # The type of target being held
724
+ sig do
725
+ returns(
726
+ ModernTreasury::PaymentOrder::CurrentHold::TargetType::TaggedSymbol
727
+ )
728
+ end
729
+ attr_accessor :target_type
730
+
731
+ sig { returns(Time) }
732
+ attr_accessor :updated_at
733
+
734
+ # This field will be true if this object exists in the live environment or false
735
+ # if it exists in the test environment.
736
+ sig { returns(T.nilable(T::Boolean)) }
737
+ attr_reader :live_mode
738
+
739
+ sig { params(live_mode: T::Boolean).void }
740
+ attr_writer :live_mode
741
+
742
+ # Additional metadata for the hold
743
+ sig { returns(T.nilable(T::Hash[Symbol, String])) }
744
+ attr_accessor :metadata
745
+
746
+ # The reason for the hold
747
+ sig { returns(T.nilable(String)) }
748
+ attr_accessor :reason
749
+
750
+ # The resolution of the hold
751
+ sig { returns(T.nilable(String)) }
752
+ attr_accessor :resolution
753
+
754
+ # When the hold was resolved
755
+ sig { returns(T.nilable(Time)) }
756
+ attr_accessor :resolved_at
757
+
758
+ # If the payment order's status is `held`, this will include the hold object's
759
+ # data.
760
+ sig do
761
+ params(
762
+ id: String,
763
+ created_at: Time,
764
+ object: ModernTreasury::PaymentOrder::CurrentHold::Object::OrSymbol,
765
+ status: ModernTreasury::PaymentOrder::CurrentHold::Status::OrSymbol,
766
+ target_id: String,
767
+ target_type:
768
+ ModernTreasury::PaymentOrder::CurrentHold::TargetType::OrSymbol,
769
+ updated_at: Time,
770
+ live_mode: T::Boolean,
771
+ metadata: T.nilable(T::Hash[Symbol, String]),
772
+ reason: T.nilable(String),
773
+ resolution: T.nilable(String),
774
+ resolved_at: T.nilable(Time)
775
+ ).returns(T.attached_class)
776
+ end
777
+ def self.new(
778
+ id:,
779
+ created_at:,
780
+ # The type of object
781
+ object:,
782
+ # The status of the hold
783
+ status:,
784
+ # The ID of the target being held
785
+ target_id:,
786
+ # The type of target being held
787
+ target_type:,
788
+ updated_at:,
789
+ # This field will be true if this object exists in the live environment or false
790
+ # if it exists in the test environment.
791
+ live_mode: nil,
792
+ # Additional metadata for the hold
793
+ metadata: nil,
794
+ # The reason for the hold
795
+ reason: nil,
796
+ # The resolution of the hold
797
+ resolution: nil,
798
+ # When the hold was resolved
799
+ resolved_at: nil
800
+ )
801
+ end
802
+
803
+ sig do
804
+ override.returns(
805
+ {
806
+ id: String,
807
+ created_at: Time,
808
+ object:
809
+ ModernTreasury::PaymentOrder::CurrentHold::Object::TaggedSymbol,
810
+ status:
811
+ ModernTreasury::PaymentOrder::CurrentHold::Status::TaggedSymbol,
812
+ target_id: String,
813
+ target_type:
814
+ ModernTreasury::PaymentOrder::CurrentHold::TargetType::TaggedSymbol,
815
+ updated_at: Time,
816
+ live_mode: T::Boolean,
817
+ metadata: T.nilable(T::Hash[Symbol, String]),
818
+ reason: T.nilable(String),
819
+ resolution: T.nilable(String),
820
+ resolved_at: T.nilable(Time)
821
+ }
822
+ )
823
+ end
824
+ def to_hash
825
+ end
826
+
827
+ # The type of object
828
+ module Object
829
+ extend ModernTreasury::Internal::Type::Enum
830
+
831
+ TaggedSymbol =
832
+ T.type_alias do
833
+ T.all(Symbol, ModernTreasury::PaymentOrder::CurrentHold::Object)
834
+ end
835
+ OrSymbol = T.type_alias { T.any(Symbol, String) }
836
+
837
+ HOLD =
838
+ T.let(
839
+ :hold,
840
+ ModernTreasury::PaymentOrder::CurrentHold::Object::TaggedSymbol
841
+ )
842
+
843
+ sig do
844
+ override.returns(
845
+ T::Array[
846
+ ModernTreasury::PaymentOrder::CurrentHold::Object::TaggedSymbol
847
+ ]
848
+ )
849
+ end
850
+ def self.values
851
+ end
852
+ end
853
+
854
+ # The status of the hold
855
+ module Status
856
+ extend ModernTreasury::Internal::Type::Enum
857
+
858
+ TaggedSymbol =
859
+ T.type_alias do
860
+ T.all(Symbol, ModernTreasury::PaymentOrder::CurrentHold::Status)
861
+ end
862
+ OrSymbol = T.type_alias { T.any(Symbol, String) }
863
+
864
+ ACTIVE =
865
+ T.let(
866
+ :active,
867
+ ModernTreasury::PaymentOrder::CurrentHold::Status::TaggedSymbol
868
+ )
869
+ RESOLVED =
870
+ T.let(
871
+ :resolved,
872
+ ModernTreasury::PaymentOrder::CurrentHold::Status::TaggedSymbol
873
+ )
874
+
875
+ sig do
876
+ override.returns(
877
+ T::Array[
878
+ ModernTreasury::PaymentOrder::CurrentHold::Status::TaggedSymbol
879
+ ]
880
+ )
881
+ end
882
+ def self.values
883
+ end
884
+ end
885
+
886
+ # The type of target being held
887
+ module TargetType
888
+ extend ModernTreasury::Internal::Type::Enum
889
+
890
+ TaggedSymbol =
891
+ T.type_alias do
892
+ T.all(
893
+ Symbol,
894
+ ModernTreasury::PaymentOrder::CurrentHold::TargetType
895
+ )
896
+ end
897
+ OrSymbol = T.type_alias { T.any(Symbol, String) }
898
+
899
+ PAYMENT_ORDER =
900
+ T.let(
901
+ :payment_order,
902
+ ModernTreasury::PaymentOrder::CurrentHold::TargetType::TaggedSymbol
903
+ )
904
+
905
+ sig do
906
+ override.returns(
907
+ T::Array[
908
+ ModernTreasury::PaymentOrder::CurrentHold::TargetType::TaggedSymbol
909
+ ]
910
+ )
911
+ end
912
+ def self.values
913
+ end
914
+ end
915
+ end
916
+
655
917
  # One of `credit`, `debit`. Describes the direction money is flowing in the
656
918
  # transaction. A `credit` moves money from your account to someone else's. A
657
919
  # `debit` pulls money from someone else's account to your own. Note that wire,
@@ -771,6 +1033,43 @@ module ModernTreasury
771
1033
  end
772
1034
  end
773
1035
 
1036
+ # One of `unreconciled`, `tentatively_reconciled` or `reconciled`.
1037
+ module ReconciliationStatus
1038
+ extend ModernTreasury::Internal::Type::Enum
1039
+
1040
+ TaggedSymbol =
1041
+ T.type_alias do
1042
+ T.all(Symbol, ModernTreasury::PaymentOrder::ReconciliationStatus)
1043
+ end
1044
+ OrSymbol = T.type_alias { T.any(Symbol, String) }
1045
+
1046
+ UNRECONCILED =
1047
+ T.let(
1048
+ :unreconciled,
1049
+ ModernTreasury::PaymentOrder::ReconciliationStatus::TaggedSymbol
1050
+ )
1051
+ TENTATIVELY_RECONCILED =
1052
+ T.let(
1053
+ :tentatively_reconciled,
1054
+ ModernTreasury::PaymentOrder::ReconciliationStatus::TaggedSymbol
1055
+ )
1056
+ RECONCILED =
1057
+ T.let(
1058
+ :reconciled,
1059
+ ModernTreasury::PaymentOrder::ReconciliationStatus::TaggedSymbol
1060
+ )
1061
+
1062
+ sig do
1063
+ override.returns(
1064
+ T::Array[
1065
+ ModernTreasury::PaymentOrder::ReconciliationStatus::TaggedSymbol
1066
+ ]
1067
+ )
1068
+ end
1069
+ def self.values
1070
+ end
1071
+ end
1072
+
774
1073
  class ReferenceNumber < ModernTreasury::Internal::Type::BaseModel
775
1074
  OrHash =
776
1075
  T.type_alias do
@@ -1146,6 +1445,11 @@ module ModernTreasury
1146
1445
  :lob_check_id,
1147
1446
  ModernTreasury::PaymentOrder::ReferenceNumber::ReferenceNumberType::TaggedSymbol
1148
1447
  )
1448
+ MT_FOF_TRANSFER_ID =
1449
+ T.let(
1450
+ :mt_fof_transfer_id,
1451
+ ModernTreasury::PaymentOrder::ReferenceNumber::ReferenceNumberType::TaggedSymbol
1452
+ )
1149
1453
  OTHER =
1150
1454
  T.let(
1151
1455
  :other,
@@ -1337,6 +1641,7 @@ module ModernTreasury
1337
1641
  T.let(:denied, ModernTreasury::PaymentOrder::Status::TaggedSymbol)
1338
1642
  FAILED =
1339
1643
  T.let(:failed, ModernTreasury::PaymentOrder::Status::TaggedSymbol)
1644
+ HELD = T.let(:held, ModernTreasury::PaymentOrder::Status::TaggedSymbol)
1340
1645
  NEEDS_APPROVAL =
1341
1646
  T.let(
1342
1647
  :needs_approval,
@@ -269,6 +269,24 @@ module ModernTreasury
269
269
  sig { params(receiving_account_id: String).void }
270
270
  attr_writer :receiving_account_id
271
271
 
272
+ # One of `unreconciled`, `tentatively_reconciled` or `reconciled`.
273
+ sig do
274
+ returns(
275
+ T.nilable(
276
+ ModernTreasury::PaymentOrderCreateAsyncParams::ReconciliationStatus::OrSymbol
277
+ )
278
+ )
279
+ end
280
+ attr_reader :reconciliation_status
281
+
282
+ sig do
283
+ params(
284
+ reconciliation_status:
285
+ ModernTreasury::PaymentOrderCreateAsyncParams::ReconciliationStatus::OrSymbol
286
+ ).void
287
+ end
288
+ attr_writer :reconciliation_status
289
+
272
290
  # For `ach`, this field will be passed through on an addenda record. For `wire`
273
291
  # payments the field will be passed through as the "Originator to Beneficiary
274
292
  # Information", also known as OBI or Fedwire tag 6000.
@@ -363,6 +381,8 @@ module ModernTreasury
363
381
  receiving_account:
364
382
  ModernTreasury::PaymentOrderCreateAsyncParams::ReceivingAccount::OrHash,
365
383
  receiving_account_id: String,
384
+ reconciliation_status:
385
+ ModernTreasury::PaymentOrderCreateAsyncParams::ReconciliationStatus::OrSymbol,
366
386
  remittance_information: T.nilable(String),
367
387
  send_remittance_advice: T.nilable(T::Boolean),
368
388
  statement_descriptor: T.nilable(String),
@@ -467,6 +487,8 @@ module ModernTreasury
467
487
  # `receiving_account_id`, you may pass the id of an external account or an
468
488
  # internal account.
469
489
  receiving_account_id: nil,
490
+ # One of `unreconciled`, `tentatively_reconciled` or `reconciled`.
491
+ reconciliation_status: nil,
470
492
  # For `ach`, this field will be passed through on an addenda record. For `wire`
471
493
  # payments the field will be passed through as the "Originator to Beneficiary
472
494
  # Information", also known as OBI or Fedwire tag 6000.
@@ -542,6 +564,8 @@ module ModernTreasury
542
564
  receiving_account:
543
565
  ModernTreasury::PaymentOrderCreateAsyncParams::ReceivingAccount,
544
566
  receiving_account_id: String,
567
+ reconciliation_status:
568
+ ModernTreasury::PaymentOrderCreateAsyncParams::ReconciliationStatus::OrSymbol,
545
569
  remittance_information: T.nilable(String),
546
570
  send_remittance_advice: T.nilable(T::Boolean),
547
571
  statement_descriptor: T.nilable(String),
@@ -1681,6 +1705,46 @@ module ModernTreasury
1681
1705
  end
1682
1706
  end
1683
1707
  end
1708
+
1709
+ # One of `unreconciled`, `tentatively_reconciled` or `reconciled`.
1710
+ module ReconciliationStatus
1711
+ extend ModernTreasury::Internal::Type::Enum
1712
+
1713
+ TaggedSymbol =
1714
+ T.type_alias do
1715
+ T.all(
1716
+ Symbol,
1717
+ ModernTreasury::PaymentOrderCreateAsyncParams::ReconciliationStatus
1718
+ )
1719
+ end
1720
+ OrSymbol = T.type_alias { T.any(Symbol, String) }
1721
+
1722
+ UNRECONCILED =
1723
+ T.let(
1724
+ :unreconciled,
1725
+ ModernTreasury::PaymentOrderCreateAsyncParams::ReconciliationStatus::TaggedSymbol
1726
+ )
1727
+ TENTATIVELY_RECONCILED =
1728
+ T.let(
1729
+ :tentatively_reconciled,
1730
+ ModernTreasury::PaymentOrderCreateAsyncParams::ReconciliationStatus::TaggedSymbol
1731
+ )
1732
+ RECONCILED =
1733
+ T.let(
1734
+ :reconciled,
1735
+ ModernTreasury::PaymentOrderCreateAsyncParams::ReconciliationStatus::TaggedSymbol
1736
+ )
1737
+
1738
+ sig do
1739
+ override.returns(
1740
+ T::Array[
1741
+ ModernTreasury::PaymentOrderCreateAsyncParams::ReconciliationStatus::TaggedSymbol
1742
+ ]
1743
+ )
1744
+ end
1745
+ def self.values
1746
+ end
1747
+ end
1684
1748
  end
1685
1749
  end
1686
1750
  end
@@ -279,6 +279,24 @@ module ModernTreasury
279
279
  sig { params(receiving_account_id: String).void }
280
280
  attr_writer :receiving_account_id
281
281
 
282
+ # One of `unreconciled`, `tentatively_reconciled` or `reconciled`.
283
+ sig do
284
+ returns(
285
+ T.nilable(
286
+ ModernTreasury::PaymentOrderCreateParams::ReconciliationStatus::OrSymbol
287
+ )
288
+ )
289
+ end
290
+ attr_reader :reconciliation_status
291
+
292
+ sig do
293
+ params(
294
+ reconciliation_status:
295
+ ModernTreasury::PaymentOrderCreateParams::ReconciliationStatus::OrSymbol
296
+ ).void
297
+ end
298
+ attr_writer :reconciliation_status
299
+
282
300
  # For `ach`, this field will be passed through on an addenda record. For `wire`
283
301
  # payments the field will be passed through as the "Originator to Beneficiary
284
302
  # Information", also known as OBI or Fedwire tag 6000.
@@ -377,6 +395,8 @@ module ModernTreasury
377
395
  receiving_account:
378
396
  ModernTreasury::PaymentOrderCreateParams::ReceivingAccount::OrHash,
379
397
  receiving_account_id: String,
398
+ reconciliation_status:
399
+ ModernTreasury::PaymentOrderCreateParams::ReconciliationStatus::OrSymbol,
380
400
  remittance_information: T.nilable(String),
381
401
  send_remittance_advice: T.nilable(T::Boolean),
382
402
  statement_descriptor: T.nilable(String),
@@ -484,6 +504,8 @@ module ModernTreasury
484
504
  # `receiving_account_id`, you may pass the id of an external account or an
485
505
  # internal account.
486
506
  receiving_account_id: nil,
507
+ # One of `unreconciled`, `tentatively_reconciled` or `reconciled`.
508
+ reconciliation_status: nil,
487
509
  # For `ach`, this field will be passed through on an addenda record. For `wire`
488
510
  # payments the field will be passed through as the "Originator to Beneficiary
489
511
  # Information", also known as OBI or Fedwire tag 6000.
@@ -560,6 +582,8 @@ module ModernTreasury
560
582
  receiving_account:
561
583
  ModernTreasury::PaymentOrderCreateParams::ReceivingAccount,
562
584
  receiving_account_id: String,
585
+ reconciliation_status:
586
+ ModernTreasury::PaymentOrderCreateParams::ReconciliationStatus::OrSymbol,
563
587
  remittance_information: T.nilable(String),
564
588
  send_remittance_advice: T.nilable(T::Boolean),
565
589
  statement_descriptor: T.nilable(String),
@@ -1831,6 +1855,46 @@ module ModernTreasury
1831
1855
  end
1832
1856
  end
1833
1857
  end
1858
+
1859
+ # One of `unreconciled`, `tentatively_reconciled` or `reconciled`.
1860
+ module ReconciliationStatus
1861
+ extend ModernTreasury::Internal::Type::Enum
1862
+
1863
+ TaggedSymbol =
1864
+ T.type_alias do
1865
+ T.all(
1866
+ Symbol,
1867
+ ModernTreasury::PaymentOrderCreateParams::ReconciliationStatus
1868
+ )
1869
+ end
1870
+ OrSymbol = T.type_alias { T.any(Symbol, String) }
1871
+
1872
+ UNRECONCILED =
1873
+ T.let(
1874
+ :unreconciled,
1875
+ ModernTreasury::PaymentOrderCreateParams::ReconciliationStatus::TaggedSymbol
1876
+ )
1877
+ TENTATIVELY_RECONCILED =
1878
+ T.let(
1879
+ :tentatively_reconciled,
1880
+ ModernTreasury::PaymentOrderCreateParams::ReconciliationStatus::TaggedSymbol
1881
+ )
1882
+ RECONCILED =
1883
+ T.let(
1884
+ :reconciled,
1885
+ ModernTreasury::PaymentOrderCreateParams::ReconciliationStatus::TaggedSymbol
1886
+ )
1887
+
1888
+ sig do
1889
+ override.returns(
1890
+ T::Array[
1891
+ ModernTreasury::PaymentOrderCreateParams::ReconciliationStatus::TaggedSymbol
1892
+ ]
1893
+ )
1894
+ end
1895
+ def self.values
1896
+ end
1897
+ end
1834
1898
  end
1835
1899
  end
1836
1900
  end
@@ -316,6 +316,11 @@ module ModernTreasury
316
316
  :failed,
317
317
  ModernTreasury::PaymentOrderListParams::Status::TaggedSymbol
318
318
  )
319
+ HELD =
320
+ T.let(
321
+ :held,
322
+ ModernTreasury::PaymentOrderListParams::Status::TaggedSymbol
323
+ )
319
324
  NEEDS_APPROVAL =
320
325
  T.let(
321
326
  :needs_approval,
@@ -251,6 +251,24 @@ module ModernTreasury
251
251
  sig { params(receiving_account_id: String).void }
252
252
  attr_writer :receiving_account_id
253
253
 
254
+ # One of `unreconciled`, `tentatively_reconciled` or `reconciled`.
255
+ sig do
256
+ returns(
257
+ T.nilable(
258
+ ModernTreasury::PaymentOrderUpdateParams::ReconciliationStatus::OrSymbol
259
+ )
260
+ )
261
+ end
262
+ attr_reader :reconciliation_status
263
+
264
+ sig do
265
+ params(
266
+ reconciliation_status:
267
+ ModernTreasury::PaymentOrderUpdateParams::ReconciliationStatus::OrSymbol
268
+ ).void
269
+ end
270
+ attr_writer :reconciliation_status
271
+
254
272
  # For `ach`, this field will be passed through on an addenda record. For `wire`
255
273
  # payments the field will be passed through as the "Originator to Beneficiary
256
274
  # Information", also known as OBI or Fedwire tag 6000.
@@ -368,6 +386,8 @@ module ModernTreasury
368
386
  receiving_account:
369
387
  ModernTreasury::PaymentOrderUpdateParams::ReceivingAccount::OrHash,
370
388
  receiving_account_id: String,
389
+ reconciliation_status:
390
+ ModernTreasury::PaymentOrderUpdateParams::ReconciliationStatus::OrSymbol,
371
391
  remittance_information: T.nilable(String),
372
392
  send_remittance_advice: T.nilable(T::Boolean),
373
393
  statement_descriptor: T.nilable(String),
@@ -461,6 +481,8 @@ module ModernTreasury
461
481
  # `receiving_account_id`, you may pass the id of an external account or an
462
482
  # internal account.
463
483
  receiving_account_id: nil,
484
+ # One of `unreconciled`, `tentatively_reconciled` or `reconciled`.
485
+ reconciliation_status: nil,
464
486
  # For `ach`, this field will be passed through on an addenda record. For `wire`
465
487
  # payments the field will be passed through as the "Originator to Beneficiary
466
488
  # Information", also known as OBI or Fedwire tag 6000.
@@ -546,6 +568,8 @@ module ModernTreasury
546
568
  receiving_account:
547
569
  ModernTreasury::PaymentOrderUpdateParams::ReceivingAccount,
548
570
  receiving_account_id: String,
571
+ reconciliation_status:
572
+ ModernTreasury::PaymentOrderUpdateParams::ReconciliationStatus::OrSymbol,
549
573
  remittance_information: T.nilable(String),
550
574
  send_remittance_advice: T.nilable(T::Boolean),
551
575
  statement_descriptor: T.nilable(String),
@@ -1681,6 +1705,46 @@ module ModernTreasury
1681
1705
  end
1682
1706
  end
1683
1707
 
1708
+ # One of `unreconciled`, `tentatively_reconciled` or `reconciled`.
1709
+ module ReconciliationStatus
1710
+ extend ModernTreasury::Internal::Type::Enum
1711
+
1712
+ TaggedSymbol =
1713
+ T.type_alias do
1714
+ T.all(
1715
+ Symbol,
1716
+ ModernTreasury::PaymentOrderUpdateParams::ReconciliationStatus
1717
+ )
1718
+ end
1719
+ OrSymbol = T.type_alias { T.any(Symbol, String) }
1720
+
1721
+ UNRECONCILED =
1722
+ T.let(
1723
+ :unreconciled,
1724
+ ModernTreasury::PaymentOrderUpdateParams::ReconciliationStatus::TaggedSymbol
1725
+ )
1726
+ TENTATIVELY_RECONCILED =
1727
+ T.let(
1728
+ :tentatively_reconciled,
1729
+ ModernTreasury::PaymentOrderUpdateParams::ReconciliationStatus::TaggedSymbol
1730
+ )
1731
+ RECONCILED =
1732
+ T.let(
1733
+ :reconciled,
1734
+ ModernTreasury::PaymentOrderUpdateParams::ReconciliationStatus::TaggedSymbol
1735
+ )
1736
+
1737
+ sig do
1738
+ override.returns(
1739
+ T::Array[
1740
+ ModernTreasury::PaymentOrderUpdateParams::ReconciliationStatus::TaggedSymbol
1741
+ ]
1742
+ )
1743
+ end
1744
+ def self.values
1745
+ end
1746
+ end
1747
+
1684
1748
  # To cancel a payment order, use `cancelled`. To redraft a returned payment order,
1685
1749
  # use `approved`. To undo approval on a denied or approved payment order, use
1686
1750
  # `needs_approval`.
@@ -1718,6 +1782,11 @@ module ModernTreasury
1718
1782
  :failed,
1719
1783
  ModernTreasury::PaymentOrderUpdateParams::Status::TaggedSymbol
1720
1784
  )
1785
+ HELD =
1786
+ T.let(
1787
+ :held,
1788
+ ModernTreasury::PaymentOrderUpdateParams::Status::TaggedSymbol
1789
+ )
1721
1790
  NEEDS_APPROVAL =
1722
1791
  T.let(
1723
1792
  :needs_approval,