lithic 0.15.0 → 0.17.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 (197) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +35 -0
  3. data/README.md +1 -1
  4. data/lib/lithic/client.rb +4 -0
  5. data/lib/lithic/internal/transport/base_client.rb +4 -1
  6. data/lib/lithic/models/account.rb +2 -2
  7. data/lib/lithic/models/account_holders/account_holder_entity.rb +3 -16
  8. data/lib/lithic/models/account_holders/entity_create_params.rb +3 -14
  9. data/lib/lithic/models/auth_rules/ach_payment_update_action.rb +108 -0
  10. data/lib/lithic/models/auth_rules/auth_rule.rb +18 -12
  11. data/lib/lithic/models/auth_rules/auth_rule_version.rb +5 -3
  12. data/lib/lithic/models/auth_rules/conditional_ach_payment_update_action_parameters.rb +142 -0
  13. data/lib/lithic/models/auth_rules/conditional_authorization_adjustment_parameters.rb +18 -20
  14. data/lib/lithic/models/auth_rules/conditional_card_transaction_update_action_parameters.rb +195 -9
  15. data/lib/lithic/models/auth_rules/event_stream.rb +1 -0
  16. data/lib/lithic/models/auth_rules/rule_feature.rb +52 -7
  17. data/lib/lithic/models/auth_rules/typescript_code_parameters.rb +2 -2
  18. data/lib/lithic/models/auth_rules/v2_create_params.rb +39 -27
  19. data/lib/lithic/models/auth_rules/v2_draft_params.rb +5 -3
  20. data/lib/lithic/models/auth_rules/v2_list_results_response.rb +426 -1
  21. data/lib/lithic/models/card.rb +1 -1
  22. data/lib/lithic/models/card_authorization.rb +117 -11
  23. data/lib/lithic/models/financial_accounts/loan_tape.rb +9 -1
  24. data/lib/lithic/models/payment.rb +13 -1
  25. data/lib/lithic/models/transaction_monitoring/case_activity_entry.rb +74 -0
  26. data/lib/lithic/models/transaction_monitoring/case_activity_type.rb +35 -0
  27. data/lib/lithic/models/transaction_monitoring/case_card.rb +37 -0
  28. data/lib/lithic/models/transaction_monitoring/case_entity.rb +50 -0
  29. data/lib/lithic/models/transaction_monitoring/case_list_activity_params.rb +53 -0
  30. data/lib/lithic/models/transaction_monitoring/case_list_params.rb +136 -0
  31. data/lib/lithic/models/transaction_monitoring/case_list_transactions_params.rb +53 -0
  32. data/lib/lithic/models/transaction_monitoring/case_priority.rb +20 -0
  33. data/lib/lithic/models/transaction_monitoring/case_retrieve_cards_params.rb +22 -0
  34. data/lib/lithic/models/transaction_monitoring/case_retrieve_cards_response.rb +11 -0
  35. data/lib/lithic/models/transaction_monitoring/case_retrieve_params.rb +22 -0
  36. data/lib/lithic/models/transaction_monitoring/case_sort_order.rb +29 -0
  37. data/lib/lithic/models/transaction_monitoring/case_status.rb +31 -0
  38. data/lib/lithic/models/transaction_monitoring/case_transaction.rb +53 -0
  39. data/lib/lithic/models/transaction_monitoring/case_update_params.rb +116 -0
  40. data/lib/lithic/models/transaction_monitoring/cases/case_file.rb +141 -0
  41. data/lib/lithic/models/transaction_monitoring/cases/comment_create_params.rb +47 -0
  42. data/lib/lithic/models/transaction_monitoring/cases/comment_delete_params.rb +30 -0
  43. data/lib/lithic/models/transaction_monitoring/cases/comment_update_params.rb +54 -0
  44. data/lib/lithic/models/transaction_monitoring/cases/file_create_params.rb +33 -0
  45. data/lib/lithic/models/transaction_monitoring/cases/file_delete_params.rb +30 -0
  46. data/lib/lithic/models/transaction_monitoring/cases/file_list_params.rb +54 -0
  47. data/lib/lithic/models/transaction_monitoring/cases/file_retrieve_params.rb +30 -0
  48. data/lib/lithic/models/transaction_monitoring/cases/file_status.rb +26 -0
  49. data/lib/lithic/models/transaction_monitoring/cases/upload_constraints.rb +31 -0
  50. data/lib/lithic/models/transaction_monitoring/entity_type.rb +18 -0
  51. data/lib/lithic/models/transaction_monitoring/monitoring_case.rb +168 -0
  52. data/lib/lithic/models/transaction_monitoring/queue.rb +120 -0
  53. data/lib/lithic/models/transaction_monitoring/queue_create_params.rb +32 -0
  54. data/lib/lithic/models/transaction_monitoring/queue_delete_params.rb +22 -0
  55. data/lib/lithic/models/transaction_monitoring/queue_list_params.rb +45 -0
  56. data/lib/lithic/models/transaction_monitoring/queue_retrieve_params.rb +22 -0
  57. data/lib/lithic/models/transaction_monitoring/queue_update_params.rb +39 -0
  58. data/lib/lithic/models/transaction_monitoring/resolution_outcome.rb +28 -0
  59. data/lib/lithic/models/transaction_route_params.rb +29 -0
  60. data/lib/lithic/models.rb +4 -0
  61. data/lib/lithic/resources/account_holders/entities.rb +1 -1
  62. data/lib/lithic/resources/auth_rules/v2.rb +2 -2
  63. data/lib/lithic/resources/cards.rb +2 -2
  64. data/lib/lithic/resources/transaction_monitoring/cases/comments.rb +111 -0
  65. data/lib/lithic/resources/transaction_monitoring/cases/files.rb +131 -0
  66. data/lib/lithic/resources/transaction_monitoring/cases.rb +228 -0
  67. data/lib/lithic/resources/transaction_monitoring/queues.rb +137 -0
  68. data/lib/lithic/resources/transaction_monitoring.rb +22 -0
  69. data/lib/lithic/resources/transactions.rb +25 -0
  70. data/lib/lithic/version.rb +1 -1
  71. data/lib/lithic.rb +42 -0
  72. data/rbi/lithic/client.rbi +3 -0
  73. data/rbi/lithic/models/account.rbi +3 -3
  74. data/rbi/lithic/models/account_holders/account_holder_entity.rbi +3 -40
  75. data/rbi/lithic/models/account_holders/entity_create_params.rbi +3 -37
  76. data/rbi/lithic/models/auth_rules/ach_payment_update_action.rbi +237 -0
  77. data/rbi/lithic/models/auth_rules/auth_rule.rbi +16 -9
  78. data/rbi/lithic/models/auth_rules/auth_rule_version.rbi +2 -0
  79. data/rbi/lithic/models/auth_rules/conditional_ach_payment_update_action_parameters.rbi +298 -0
  80. data/rbi/lithic/models/auth_rules/conditional_authorization_adjustment_parameters.rbi +29 -29
  81. data/rbi/lithic/models/auth_rules/conditional_card_transaction_update_action_parameters.rbi +395 -12
  82. data/rbi/lithic/models/auth_rules/event_stream.rbi +5 -0
  83. data/rbi/lithic/models/auth_rules/rule_feature.rbi +77 -6
  84. data/rbi/lithic/models/auth_rules/typescript_code_parameters.rbi +6 -0
  85. data/rbi/lithic/models/auth_rules/v2_create_params.rbi +48 -27
  86. data/rbi/lithic/models/auth_rules/v2_draft_params.rbi +4 -0
  87. data/rbi/lithic/models/auth_rules/v2_list_results_response.rbi +826 -1
  88. data/rbi/lithic/models/card.rbi +2 -2
  89. data/rbi/lithic/models/card_authorization.rbi +246 -17
  90. data/rbi/lithic/models/financial_accounts/loan_tape.rbi +8 -0
  91. data/rbi/lithic/models/payment.rbi +13 -0
  92. data/rbi/lithic/models/transaction_monitoring/case_activity_entry.rbi +107 -0
  93. data/rbi/lithic/models/transaction_monitoring/case_activity_type.rbi +84 -0
  94. data/rbi/lithic/models/transaction_monitoring/case_card.rbi +60 -0
  95. data/rbi/lithic/models/transaction_monitoring/case_entity.rbi +101 -0
  96. data/rbi/lithic/models/transaction_monitoring/case_list_activity_params.rbi +83 -0
  97. data/rbi/lithic/models/transaction_monitoring/case_list_params.rbi +220 -0
  98. data/rbi/lithic/models/transaction_monitoring/case_list_transactions_params.rbi +83 -0
  99. data/rbi/lithic/models/transaction_monitoring/case_priority.rbi +44 -0
  100. data/rbi/lithic/models/transaction_monitoring/case_retrieve_cards_params.rbi +40 -0
  101. data/rbi/lithic/models/transaction_monitoring/case_retrieve_cards_response.rbi +15 -0
  102. data/rbi/lithic/models/transaction_monitoring/case_retrieve_params.rbi +40 -0
  103. data/rbi/lithic/models/transaction_monitoring/case_sort_order.rbi +64 -0
  104. data/rbi/lithic/models/transaction_monitoring/case_status.rbi +63 -0
  105. data/rbi/lithic/models/transaction_monitoring/case_transaction.rbi +75 -0
  106. data/rbi/lithic/models/transaction_monitoring/case_update_params.rbi +201 -0
  107. data/rbi/lithic/models/transaction_monitoring/cases/case_file.rbi +188 -0
  108. data/rbi/lithic/models/transaction_monitoring/cases/comment_create_params.rbi +71 -0
  109. data/rbi/lithic/models/transaction_monitoring/cases/comment_delete_params.rbi +50 -0
  110. data/rbi/lithic/models/transaction_monitoring/cases/comment_update_params.rbi +77 -0
  111. data/rbi/lithic/models/transaction_monitoring/cases/file_create_params.rbi +56 -0
  112. data/rbi/lithic/models/transaction_monitoring/cases/file_delete_params.rbi +50 -0
  113. data/rbi/lithic/models/transaction_monitoring/cases/file_list_params.rbi +85 -0
  114. data/rbi/lithic/models/transaction_monitoring/cases/file_retrieve_params.rbi +50 -0
  115. data/rbi/lithic/models/transaction_monitoring/cases/file_status.rbi +51 -0
  116. data/rbi/lithic/models/transaction_monitoring/cases/upload_constraints.rbi +51 -0
  117. data/rbi/lithic/models/transaction_monitoring/entity_type.rbi +37 -0
  118. data/rbi/lithic/models/transaction_monitoring/monitoring_case.rbi +226 -0
  119. data/rbi/lithic/models/transaction_monitoring/queue.rbi +189 -0
  120. data/rbi/lithic/models/transaction_monitoring/queue_create_params.rbi +56 -0
  121. data/rbi/lithic/models/transaction_monitoring/queue_delete_params.rbi +40 -0
  122. data/rbi/lithic/models/transaction_monitoring/queue_list_params.rbi +77 -0
  123. data/rbi/lithic/models/transaction_monitoring/queue_retrieve_params.rbi +40 -0
  124. data/rbi/lithic/models/transaction_monitoring/queue_update_params.rbi +65 -0
  125. data/rbi/lithic/models/transaction_monitoring/resolution_outcome.rbi +61 -0
  126. data/rbi/lithic/models/transaction_route_params.rbi +49 -0
  127. data/rbi/lithic/models.rbi +4 -0
  128. data/rbi/lithic/resources/account_holders/entities.rbi +1 -1
  129. data/rbi/lithic/resources/auth_rules/v2.rbi +1 -0
  130. data/rbi/lithic/resources/cards.rbi +2 -2
  131. data/rbi/lithic/resources/transaction_monitoring/cases/comments.rbi +81 -0
  132. data/rbi/lithic/resources/transaction_monitoring/cases/files.rbi +98 -0
  133. data/rbi/lithic/resources/transaction_monitoring/cases.rbi +230 -0
  134. data/rbi/lithic/resources/transaction_monitoring/queues.rbi +103 -0
  135. data/rbi/lithic/resources/transaction_monitoring.rbi +18 -0
  136. data/rbi/lithic/resources/transactions.rbi +18 -0
  137. data/sig/lithic/client.rbs +2 -0
  138. data/sig/lithic/models/account_holders/account_holder_entity.rbs +4 -15
  139. data/sig/lithic/models/account_holders/entity_create_params.rbs +4 -15
  140. data/sig/lithic/models/auth_rules/ach_payment_update_action.rbs +99 -0
  141. data/sig/lithic/models/auth_rules/auth_rule.rbs +2 -0
  142. data/sig/lithic/models/auth_rules/auth_rule_version.rbs +1 -0
  143. data/sig/lithic/models/auth_rules/conditional_ach_payment_update_action_parameters.rbs +81 -0
  144. data/sig/lithic/models/auth_rules/conditional_authorization_adjustment_parameters.rbs +16 -16
  145. data/sig/lithic/models/auth_rules/conditional_card_transaction_update_action_parameters.rbs +73 -3
  146. data/sig/lithic/models/auth_rules/event_stream.rbs +2 -0
  147. data/sig/lithic/models/auth_rules/rule_feature.rbs +31 -0
  148. data/sig/lithic/models/auth_rules/v2_create_params.rbs +3 -0
  149. data/sig/lithic/models/auth_rules/v2_draft_params.rbs +1 -0
  150. data/sig/lithic/models/auth_rules/v2_list_results_response.rbs +355 -0
  151. data/sig/lithic/models/card_authorization.rbs +84 -10
  152. data/sig/lithic/models/financial_accounts/loan_tape.rbs +5 -0
  153. data/sig/lithic/models/payment.rbs +7 -0
  154. data/sig/lithic/models/transaction_monitoring/case_activity_entry.rbs +47 -0
  155. data/sig/lithic/models/transaction_monitoring/case_activity_type.rbs +32 -0
  156. data/sig/lithic/models/transaction_monitoring/case_card.rbs +32 -0
  157. data/sig/lithic/models/transaction_monitoring/case_entity.rbs +38 -0
  158. data/sig/lithic/models/transaction_monitoring/case_list_activity_params.rbs +49 -0
  159. data/sig/lithic/models/transaction_monitoring/case_list_params.rbs +125 -0
  160. data/sig/lithic/models/transaction_monitoring/case_list_transactions_params.rbs +49 -0
  161. data/sig/lithic/models/transaction_monitoring/case_priority.rbs +18 -0
  162. data/sig/lithic/models/transaction_monitoring/case_retrieve_cards_params.rbs +25 -0
  163. data/sig/lithic/models/transaction_monitoring/case_retrieve_cards_response.rbs +10 -0
  164. data/sig/lithic/models/transaction_monitoring/case_retrieve_params.rbs +25 -0
  165. data/sig/lithic/models/transaction_monitoring/case_sort_order.rbs +26 -0
  166. data/sig/lithic/models/transaction_monitoring/case_status.rbs +21 -0
  167. data/sig/lithic/models/transaction_monitoring/case_transaction.rbs +42 -0
  168. data/sig/lithic/models/transaction_monitoring/case_update_params.rbs +91 -0
  169. data/sig/lithic/models/transaction_monitoring/cases/case_file.rbs +86 -0
  170. data/sig/lithic/models/transaction_monitoring/cases/comment_create_params.rbs +38 -0
  171. data/sig/lithic/models/transaction_monitoring/cases/comment_delete_params.rbs +32 -0
  172. data/sig/lithic/models/transaction_monitoring/cases/comment_update_params.rbs +47 -0
  173. data/sig/lithic/models/transaction_monitoring/cases/file_create_params.rbs +32 -0
  174. data/sig/lithic/models/transaction_monitoring/cases/file_delete_params.rbs +32 -0
  175. data/sig/lithic/models/transaction_monitoring/cases/file_list_params.rbs +51 -0
  176. data/sig/lithic/models/transaction_monitoring/cases/file_retrieve_params.rbs +32 -0
  177. data/sig/lithic/models/transaction_monitoring/cases/file_status.rbs +19 -0
  178. data/sig/lithic/models/transaction_monitoring/cases/upload_constraints.rbs +26 -0
  179. data/sig/lithic/models/transaction_monitoring/entity_type.rbs +16 -0
  180. data/sig/lithic/models/transaction_monitoring/monitoring_case.rbs +102 -0
  181. data/sig/lithic/models/transaction_monitoring/queue.rbs +101 -0
  182. data/sig/lithic/models/transaction_monitoring/queue_create_params.rbs +30 -0
  183. data/sig/lithic/models/transaction_monitoring/queue_delete_params.rbs +25 -0
  184. data/sig/lithic/models/transaction_monitoring/queue_list_params.rbs +40 -0
  185. data/sig/lithic/models/transaction_monitoring/queue_retrieve_params.rbs +25 -0
  186. data/sig/lithic/models/transaction_monitoring/queue_update_params.rbs +36 -0
  187. data/sig/lithic/models/transaction_monitoring/resolution_outcome.rbs +24 -0
  188. data/sig/lithic/models/transaction_route_params.rbs +28 -0
  189. data/sig/lithic/models.rbs +4 -0
  190. data/sig/lithic/resources/account_holders/entities.rbs +1 -1
  191. data/sig/lithic/resources/transaction_monitoring/cases/comments.rbs +32 -0
  192. data/sig/lithic/resources/transaction_monitoring/cases/files.rbs +37 -0
  193. data/sig/lithic/resources/transaction_monitoring/cases.rbs +71 -0
  194. data/sig/lithic/resources/transaction_monitoring/queues.rbs +39 -0
  195. data/sig/lithic/resources/transaction_monitoring.rbs +11 -0
  196. data/sig/lithic/resources/transactions.rbs +6 -0
  197. metadata +128 -2
@@ -0,0 +1,81 @@
1
+ # typed: strong
2
+
3
+ module Lithic
4
+ module Resources
5
+ class TransactionMonitoring
6
+ class Cases
7
+ class Comments
8
+ # Adds a comment to a case.
9
+ sig do
10
+ params(
11
+ case_token: String,
12
+ comment: String,
13
+ actor_token: String,
14
+ request_options: Lithic::RequestOptions::OrHash
15
+ ).returns(Lithic::TransactionMonitoring::CaseActivityEntry)
16
+ end
17
+ def create(
18
+ # Globally unique identifier for the case.
19
+ case_token,
20
+ # Text of the comment
21
+ comment:,
22
+ # Optional client-provided identifier for the actor performing this action,
23
+ # recorded on the resulting activity entry. This value is supplied by the client
24
+ # (for example, your own internal user ID) and is not authenticated by Lithic
25
+ actor_token: nil,
26
+ request_options: {}
27
+ )
28
+ end
29
+
30
+ # Edits an existing comment on a case.
31
+ sig do
32
+ params(
33
+ comment_token: String,
34
+ case_token: String,
35
+ comment: String,
36
+ actor_token: String,
37
+ request_options: Lithic::RequestOptions::OrHash
38
+ ).returns(Lithic::TransactionMonitoring::CaseActivityEntry)
39
+ end
40
+ def update(
41
+ # Path param: Globally unique identifier for the comment.
42
+ comment_token,
43
+ # Path param: Globally unique identifier for the case.
44
+ case_token:,
45
+ # Body param: New text of the comment
46
+ comment:,
47
+ # Body param: Optional client-provided identifier for the actor performing this
48
+ # action, recorded on the resulting activity entry. This value is supplied by the
49
+ # client (for example, your own internal user ID) and is not authenticated by
50
+ # Lithic
51
+ actor_token: nil,
52
+ request_options: {}
53
+ )
54
+ end
55
+
56
+ # Deletes a comment from a case.
57
+ sig do
58
+ params(
59
+ comment_token: String,
60
+ case_token: String,
61
+ request_options: Lithic::RequestOptions::OrHash
62
+ ).void
63
+ end
64
+ def delete(
65
+ # Globally unique identifier for the comment.
66
+ comment_token,
67
+ # Globally unique identifier for the case.
68
+ case_token:,
69
+ request_options: {}
70
+ )
71
+ end
72
+
73
+ # @api private
74
+ sig { params(client: Lithic::Client).returns(T.attached_class) }
75
+ def self.new(client:)
76
+ end
77
+ end
78
+ end
79
+ end
80
+ end
81
+ end
@@ -0,0 +1,98 @@
1
+ # typed: strong
2
+
3
+ module Lithic
4
+ module Resources
5
+ class TransactionMonitoring
6
+ class Cases
7
+ class Files
8
+ # Creates a file record and returns a presigned URL for uploading the file to the
9
+ # case.
10
+ sig do
11
+ params(
12
+ case_token: String,
13
+ name: String,
14
+ request_options: Lithic::RequestOptions::OrHash
15
+ ).returns(Lithic::TransactionMonitoring::Cases::CaseFile)
16
+ end
17
+ def create(
18
+ # Globally unique identifier for the case.
19
+ case_token,
20
+ # Name of the file to upload
21
+ name:,
22
+ request_options: {}
23
+ )
24
+ end
25
+
26
+ # Retrieves a single file attached to a case, including a presigned download URL
27
+ # when the file is ready.
28
+ sig do
29
+ params(
30
+ file_token: String,
31
+ case_token: String,
32
+ request_options: Lithic::RequestOptions::OrHash
33
+ ).returns(Lithic::TransactionMonitoring::Cases::CaseFile)
34
+ end
35
+ def retrieve(
36
+ # Globally unique identifier for the file.
37
+ file_token,
38
+ # Globally unique identifier for the case.
39
+ case_token:,
40
+ request_options: {}
41
+ )
42
+ end
43
+
44
+ # Lists the files attached to a case.
45
+ sig do
46
+ params(
47
+ case_token: String,
48
+ ending_before: String,
49
+ page_size: Integer,
50
+ starting_after: String,
51
+ request_options: Lithic::RequestOptions::OrHash
52
+ ).returns(
53
+ Lithic::Internal::CursorPage[
54
+ Lithic::TransactionMonitoring::Cases::CaseFile
55
+ ]
56
+ )
57
+ end
58
+ def list(
59
+ # Globally unique identifier for the case.
60
+ case_token,
61
+ # A cursor representing an item's token before which a page of results should end.
62
+ # Used to retrieve the previous page of results before this item.
63
+ ending_before: nil,
64
+ # Page size (for pagination).
65
+ page_size: nil,
66
+ # A cursor representing an item's token after which a page of results should
67
+ # begin. Used to retrieve the next page of results after this item.
68
+ starting_after: nil,
69
+ request_options: {}
70
+ )
71
+ end
72
+
73
+ # Deletes a file from a case.
74
+ sig do
75
+ params(
76
+ file_token: String,
77
+ case_token: String,
78
+ request_options: Lithic::RequestOptions::OrHash
79
+ ).void
80
+ end
81
+ def delete(
82
+ # Globally unique identifier for the file.
83
+ file_token,
84
+ # Globally unique identifier for the case.
85
+ case_token:,
86
+ request_options: {}
87
+ )
88
+ end
89
+
90
+ # @api private
91
+ sig { params(client: Lithic::Client).returns(T.attached_class) }
92
+ def self.new(client:)
93
+ end
94
+ end
95
+ end
96
+ end
97
+ end
98
+ end
@@ -0,0 +1,230 @@
1
+ # typed: strong
2
+
3
+ module Lithic
4
+ module Resources
5
+ class TransactionMonitoring
6
+ class Cases
7
+ sig do
8
+ returns(Lithic::Resources::TransactionMonitoring::Cases::Comments)
9
+ end
10
+ attr_reader :comments
11
+
12
+ sig { returns(Lithic::Resources::TransactionMonitoring::Cases::Files) }
13
+ attr_reader :files
14
+
15
+ # Retrieves a single transaction monitoring case.
16
+ sig do
17
+ params(
18
+ case_token: String,
19
+ request_options: Lithic::RequestOptions::OrHash
20
+ ).returns(Lithic::TransactionMonitoring::MonitoringCase)
21
+ end
22
+ def retrieve(
23
+ # Globally unique identifier for the case.
24
+ case_token,
25
+ request_options: {}
26
+ )
27
+ end
28
+
29
+ # Updates a transaction monitoring case.
30
+ sig do
31
+ params(
32
+ case_token: String,
33
+ actor_token: String,
34
+ assignee: T.nilable(String),
35
+ priority: Lithic::TransactionMonitoring::CasePriority::OrSymbol,
36
+ resolution:
37
+ Lithic::TransactionMonitoring::ResolutionOutcome::OrSymbol,
38
+ resolution_notes: String,
39
+ sla_deadline: T.nilable(Time),
40
+ status: Lithic::TransactionMonitoring::CaseStatus::OrSymbol,
41
+ tags: T::Hash[Symbol, String],
42
+ title: T.nilable(String),
43
+ request_options: Lithic::RequestOptions::OrHash
44
+ ).returns(Lithic::TransactionMonitoring::MonitoringCase)
45
+ end
46
+ def update(
47
+ # Globally unique identifier for the case.
48
+ case_token,
49
+ # Optional client-provided identifier for the actor performing this action,
50
+ # recorded on the resulting activity entry. This value is supplied by the client
51
+ # (for example, your own internal user ID) and is not authenticated by Lithic
52
+ actor_token: nil,
53
+ # New assignee for the case, or `null` to unassign
54
+ assignee: nil,
55
+ # Priority level of a case, controlling queue ordering and SLA urgency
56
+ priority: nil,
57
+ # Outcome recorded when a case is resolved:
58
+ #
59
+ # - `CONFIRMED_FRAUD` - The reviewed activity was confirmed to be fraudulent
60
+ # - `SUSPICIOUS_ACTIVITY` - The activity is suspicious but not confirmed fraud
61
+ # - `FALSE_POSITIVE` - The activity was legitimate and the alert was a false
62
+ # positive
63
+ # - `NO_ACTION_REQUIRED` - No further action is required
64
+ # - `ESCALATED_EXTERNAL` - The case was escalated to an external party
65
+ resolution: nil,
66
+ # Notes describing the resolution
67
+ resolution_notes: nil,
68
+ # New SLA deadline for the case, or `null` to clear it
69
+ sla_deadline: nil,
70
+ # Status of a case as it progresses through the review workflow:
71
+ #
72
+ # - `OPEN` - The case has been created and is still collecting matching
73
+ # transactions
74
+ # - `ASSIGNED` - An analyst has been assigned and transaction collection has
75
+ # stopped
76
+ # - `IN_REVIEW` - The case is actively being investigated
77
+ # - `ESCALATED` - The case has been reviewed and requires additional oversight
78
+ # - `RESOLVED` - A determination has been made and a resolution recorded
79
+ # - `CLOSED` - The case is finalized
80
+ status: nil,
81
+ # Arbitrary key-value metadata to set on the case
82
+ tags: nil,
83
+ # New title for the case, or `null` to clear it
84
+ title: nil,
85
+ request_options: {}
86
+ )
87
+ end
88
+
89
+ # Lists transaction monitoring cases, optionally filtered.
90
+ sig do
91
+ params(
92
+ account_token: String,
93
+ assignee: String,
94
+ begin_: Time,
95
+ card_token: String,
96
+ end_: Time,
97
+ ending_before: String,
98
+ entity_token: String,
99
+ page_size: Integer,
100
+ queue_token: String,
101
+ rule_token: String,
102
+ sort_by: Lithic::TransactionMonitoring::CaseSortOrder::OrSymbol,
103
+ starting_after: String,
104
+ status: Lithic::TransactionMonitoring::CaseStatus::OrSymbol,
105
+ transaction_token: String,
106
+ request_options: Lithic::RequestOptions::OrHash
107
+ ).returns(
108
+ Lithic::Internal::CursorPage[
109
+ Lithic::TransactionMonitoring::MonitoringCase
110
+ ]
111
+ )
112
+ end
113
+ def list(
114
+ # Only return cases that include transactions on the provided account.
115
+ account_token: nil,
116
+ # Only return cases assigned to the provided value. Pass an empty string to return
117
+ # only unassigned cases.
118
+ assignee: nil,
119
+ # Date string in RFC 3339 format. Only entries created after the specified time
120
+ # will be included. UTC time zone.
121
+ begin_: nil,
122
+ # Only return cases that include transactions on the provided card.
123
+ card_token: nil,
124
+ # Date string in RFC 3339 format. Only entries created before the specified time
125
+ # will be included. UTC time zone.
126
+ end_: nil,
127
+ # A cursor representing an item's token before which a page of results should end.
128
+ # Used to retrieve the previous page of results before this item.
129
+ ending_before: nil,
130
+ # Only return cases associated with the provided entity.
131
+ entity_token: nil,
132
+ # Page size (for pagination).
133
+ page_size: nil,
134
+ # Only return cases belonging to the provided queue.
135
+ queue_token: nil,
136
+ # Only return cases triggered by the provided transaction monitoring rule.
137
+ rule_token: nil,
138
+ # Sort order for the returned cases.
139
+ sort_by: nil,
140
+ # A cursor representing an item's token after which a page of results should
141
+ # begin. Used to retrieve the next page of results after this item.
142
+ starting_after: nil,
143
+ # Only return cases with the provided status.
144
+ status: nil,
145
+ # Only return cases that include the provided transaction.
146
+ transaction_token: nil,
147
+ request_options: {}
148
+ )
149
+ end
150
+
151
+ # Lists the activity feed for a case.
152
+ sig do
153
+ params(
154
+ case_token: String,
155
+ ending_before: String,
156
+ page_size: Integer,
157
+ starting_after: String,
158
+ request_options: Lithic::RequestOptions::OrHash
159
+ ).returns(
160
+ Lithic::Internal::CursorPage[
161
+ Lithic::TransactionMonitoring::CaseActivityEntry
162
+ ]
163
+ )
164
+ end
165
+ def list_activity(
166
+ # Globally unique identifier for the case.
167
+ case_token,
168
+ # A cursor representing an item's token before which a page of results should end.
169
+ # Used to retrieve the previous page of results before this item.
170
+ ending_before: nil,
171
+ # Page size (for pagination).
172
+ page_size: nil,
173
+ # A cursor representing an item's token after which a page of results should
174
+ # begin. Used to retrieve the next page of results after this item.
175
+ starting_after: nil,
176
+ request_options: {}
177
+ )
178
+ end
179
+
180
+ # Lists the transactions associated with a case.
181
+ sig do
182
+ params(
183
+ case_token: String,
184
+ ending_before: String,
185
+ page_size: Integer,
186
+ starting_after: String,
187
+ request_options: Lithic::RequestOptions::OrHash
188
+ ).returns(
189
+ Lithic::Internal::CursorPage[
190
+ Lithic::TransactionMonitoring::CaseTransaction
191
+ ]
192
+ )
193
+ end
194
+ def list_transactions(
195
+ # Globally unique identifier for the case.
196
+ case_token,
197
+ # A cursor representing an item's token before which a page of results should end.
198
+ # Used to retrieve the previous page of results before this item.
199
+ ending_before: nil,
200
+ # Page size (for pagination).
201
+ page_size: nil,
202
+ # A cursor representing an item's token after which a page of results should
203
+ # begin. Used to retrieve the next page of results after this item.
204
+ starting_after: nil,
205
+ request_options: {}
206
+ )
207
+ end
208
+
209
+ # Lists the cards involved in a case, with per-card transaction counts.
210
+ sig do
211
+ params(
212
+ case_token: String,
213
+ request_options: Lithic::RequestOptions::OrHash
214
+ ).returns(T::Array[Lithic::TransactionMonitoring::CaseCard])
215
+ end
216
+ def retrieve_cards(
217
+ # Globally unique identifier for the case.
218
+ case_token,
219
+ request_options: {}
220
+ )
221
+ end
222
+
223
+ # @api private
224
+ sig { params(client: Lithic::Client).returns(T.attached_class) }
225
+ def self.new(client:)
226
+ end
227
+ end
228
+ end
229
+ end
230
+ end
@@ -0,0 +1,103 @@
1
+ # typed: strong
2
+
3
+ module Lithic
4
+ module Resources
5
+ class TransactionMonitoring
6
+ class Queues
7
+ # Creates a new queue for grouping transaction monitoring cases.
8
+ sig do
9
+ params(
10
+ name: String,
11
+ description: T.nilable(String),
12
+ request_options: Lithic::RequestOptions::OrHash
13
+ ).returns(Lithic::TransactionMonitoring::Queue)
14
+ end
15
+ def create(
16
+ # Human-readable name of the queue
17
+ name:,
18
+ # Optional description of the queue
19
+ description: nil,
20
+ request_options: {}
21
+ )
22
+ end
23
+
24
+ # Retrieves a single transaction monitoring queue.
25
+ sig do
26
+ params(
27
+ queue_token: String,
28
+ request_options: Lithic::RequestOptions::OrHash
29
+ ).returns(Lithic::TransactionMonitoring::Queue)
30
+ end
31
+ def retrieve(
32
+ # Globally unique identifier for the queue.
33
+ queue_token,
34
+ request_options: {}
35
+ )
36
+ end
37
+
38
+ # Updates a transaction monitoring queue.
39
+ sig do
40
+ params(
41
+ queue_token: String,
42
+ description: T.nilable(String),
43
+ name: String,
44
+ request_options: Lithic::RequestOptions::OrHash
45
+ ).returns(Lithic::TransactionMonitoring::Queue)
46
+ end
47
+ def update(
48
+ # Globally unique identifier for the queue.
49
+ queue_token,
50
+ # New description for the queue, or `null` to clear it
51
+ description: nil,
52
+ # New name for the queue
53
+ name: nil,
54
+ request_options: {}
55
+ )
56
+ end
57
+
58
+ # Lists transaction monitoring queues.
59
+ sig do
60
+ params(
61
+ ending_before: String,
62
+ page_size: Integer,
63
+ starting_after: String,
64
+ request_options: Lithic::RequestOptions::OrHash
65
+ ).returns(
66
+ Lithic::Internal::CursorPage[Lithic::TransactionMonitoring::Queue]
67
+ )
68
+ end
69
+ def list(
70
+ # A cursor representing an item's token before which a page of results should end.
71
+ # Used to retrieve the previous page of results before this item.
72
+ ending_before: nil,
73
+ # Page size (for pagination).
74
+ page_size: nil,
75
+ # A cursor representing an item's token after which a page of results should
76
+ # begin. Used to retrieve the next page of results after this item.
77
+ starting_after: nil,
78
+ request_options: {}
79
+ )
80
+ end
81
+
82
+ # Deletes a transaction monitoring queue.
83
+ sig do
84
+ params(
85
+ queue_token: String,
86
+ request_options: Lithic::RequestOptions::OrHash
87
+ ).void
88
+ end
89
+ def delete(
90
+ # Globally unique identifier for the queue.
91
+ queue_token,
92
+ request_options: {}
93
+ )
94
+ end
95
+
96
+ # @api private
97
+ sig { params(client: Lithic::Client).returns(T.attached_class) }
98
+ def self.new(client:)
99
+ end
100
+ end
101
+ end
102
+ end
103
+ end
@@ -0,0 +1,18 @@
1
+ # typed: strong
2
+
3
+ module Lithic
4
+ module Resources
5
+ class TransactionMonitoring
6
+ sig { returns(Lithic::Resources::TransactionMonitoring::Cases) }
7
+ attr_reader :cases
8
+
9
+ sig { returns(Lithic::Resources::TransactionMonitoring::Queues) }
10
+ attr_reader :queues
11
+
12
+ # @api private
13
+ sig { params(client: Lithic::Client).returns(T.attached_class) }
14
+ def self.new(client:)
15
+ end
16
+ end
17
+ end
18
+ end
@@ -82,6 +82,24 @@ module Lithic
82
82
  )
83
83
  end
84
84
 
85
+ # Route a card transaction to a financial account. Only available for select use
86
+ # cases and programs.
87
+ sig do
88
+ params(
89
+ transaction_token: String,
90
+ financial_account_token: String,
91
+ request_options: Lithic::RequestOptions::OrHash
92
+ ).void
93
+ end
94
+ def route(
95
+ # The token of the transaction to route.
96
+ transaction_token,
97
+ # The token of the financial account to route the transaction to.
98
+ financial_account_token:,
99
+ request_options: {}
100
+ )
101
+ end
102
+
85
103
  # Simulates an authorization request from the card network as if it came from a
86
104
  # merchant acquirer. If you are configured for ASA, simulating authorizations
87
105
  # requires your ASA client to be set up properly, i.e. be able to respond to the
@@ -23,6 +23,8 @@ module Lithic
23
23
 
24
24
  attr_reader auth_rules: Lithic::Resources::AuthRules
25
25
 
26
+ attr_reader transaction_monitoring: Lithic::Resources::TransactionMonitoring
27
+
26
28
  attr_reader auth_stream_enrollment: Lithic::Resources::AuthStreamEnrollment
27
29
 
28
30
  attr_reader tokenization_decisioning: Lithic::Resources::TokenizationDecisioning
@@ -14,7 +14,7 @@ module Lithic
14
14
  last_name: String?,
15
15
  phone_number: String?,
16
16
  status: Lithic::Models::AccountHolders::AccountHolderEntity::status,
17
- type: Lithic::Models::AccountHolders::AccountHolderEntity::type_
17
+ type: Lithic::Models::TransactionMonitoring::entity_type
18
18
  }
19
19
 
20
20
  class AccountHolderEntity < Lithic::Internal::Type::BaseModel
@@ -36,7 +36,7 @@ module Lithic
36
36
 
37
37
  attr_accessor status: Lithic::Models::AccountHolders::AccountHolderEntity::status
38
38
 
39
- attr_accessor type: Lithic::Models::AccountHolders::AccountHolderEntity::type_
39
+ attr_accessor type: Lithic::Models::TransactionMonitoring::entity_type
40
40
 
41
41
  def initialize: (
42
42
  token: String,
@@ -48,7 +48,7 @@ module Lithic
48
48
  last_name: String?,
49
49
  phone_number: String?,
50
50
  status: Lithic::Models::AccountHolders::AccountHolderEntity::status,
51
- type: Lithic::Models::AccountHolders::AccountHolderEntity::type_
51
+ type: Lithic::Models::TransactionMonitoring::entity_type
52
52
  ) -> void
53
53
 
54
54
  def to_hash: -> {
@@ -61,7 +61,7 @@ module Lithic
61
61
  last_name: String?,
62
62
  phone_number: String?,
63
63
  status: Lithic::Models::AccountHolders::AccountHolderEntity::status,
64
- type: Lithic::Models::AccountHolders::AccountHolderEntity::type_
64
+ type: Lithic::Models::TransactionMonitoring::entity_type
65
65
  }
66
66
 
67
67
  type address =
@@ -120,17 +120,6 @@ module Lithic
120
120
 
121
121
  def self?.values: -> ::Array[Lithic::Models::AccountHolders::AccountHolderEntity::status]
122
122
  end
123
-
124
- type type_ = :BENEFICIAL_OWNER_INDIVIDUAL | :CONTROL_PERSON
125
-
126
- module Type
127
- extend Lithic::Internal::Type::Enum
128
-
129
- BENEFICIAL_OWNER_INDIVIDUAL: :BENEFICIAL_OWNER_INDIVIDUAL
130
- CONTROL_PERSON: :CONTROL_PERSON
131
-
132
- def self?.values: -> ::Array[Lithic::Models::AccountHolders::AccountHolderEntity::type_]
133
- end
134
123
  end
135
124
  end
136
125
  end
@@ -11,7 +11,7 @@ module Lithic
11
11
  government_id: String,
12
12
  last_name: String,
13
13
  phone_number: String,
14
- type: Lithic::Models::AccountHolders::EntityCreateParams::type_
14
+ type: Lithic::Models::TransactionMonitoring::entity_type
15
15
  }
16
16
  & Lithic::Internal::Type::request_parameters
17
17
 
@@ -35,7 +35,7 @@ module Lithic
35
35
 
36
36
  attr_accessor phone_number: String
37
37
 
38
- attr_accessor type: Lithic::Models::AccountHolders::EntityCreateParams::type_
38
+ attr_accessor type: Lithic::Models::TransactionMonitoring::entity_type
39
39
 
40
40
  def initialize: (
41
41
  account_holder_token: String,
@@ -46,7 +46,7 @@ module Lithic
46
46
  government_id: String,
47
47
  last_name: String,
48
48
  phone_number: String,
49
- type: Lithic::Models::AccountHolders::EntityCreateParams::type_,
49
+ type: Lithic::Models::TransactionMonitoring::entity_type,
50
50
  ?request_options: Lithic::request_opts
51
51
  ) -> void
52
52
 
@@ -59,7 +59,7 @@ module Lithic
59
59
  government_id: String,
60
60
  last_name: String,
61
61
  phone_number: String,
62
- type: Lithic::Models::AccountHolders::EntityCreateParams::type_,
62
+ type: Lithic::Models::TransactionMonitoring::entity_type,
63
63
  request_options: Lithic::RequestOptions
64
64
  }
65
65
 
@@ -106,17 +106,6 @@ module Lithic
106
106
  :address2 => String
107
107
  }
108
108
  end
109
-
110
- type type_ = :BENEFICIAL_OWNER_INDIVIDUAL | :CONTROL_PERSON
111
-
112
- module Type
113
- extend Lithic::Internal::Type::Enum
114
-
115
- BENEFICIAL_OWNER_INDIVIDUAL: :BENEFICIAL_OWNER_INDIVIDUAL
116
- CONTROL_PERSON: :CONTROL_PERSON
117
-
118
- def self?.values: -> ::Array[Lithic::Models::AccountHolders::EntityCreateParams::type_]
119
- end
120
109
  end
121
110
  end
122
111
  end