lithic 0.17.0 → 0.18.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.
- checksums.yaml +4 -4
- data/CHANGELOG.md +13 -0
- data/README.md +1 -1
- data/lib/lithic/models/auth_rules/rule_feature.rb +291 -2
- data/lib/lithic/models/auth_rules/typescript_code_parameters.rb +2 -2
- data/lib/lithic/models/claim_created_webhook_event.rb +190 -0
- data/lib/lithic/models/claim_document_accepted_webhook_event.rb +175 -0
- data/lib/lithic/models/claim_document_rejected_webhook_event.rb +175 -0
- data/lib/lithic/models/claim_document_uploaded_webhook_event.rb +175 -0
- data/lib/lithic/models/claim_updated_webhook_event.rb +190 -0
- data/lib/lithic/models/event.rb +23 -0
- data/lib/lithic/models/event_list_params.rb +14 -0
- data/lib/lithic/models/event_subscription.rb +14 -0
- data/lib/lithic/models/events/subscription_create_params.rb +14 -0
- data/lib/lithic/models/events/subscription_send_simulated_example_params.rb +5 -0
- data/lib/lithic/models/events/subscription_update_params.rb +14 -0
- data/lib/lithic/models/parsed_webhook_event.rb +11 -1
- data/lib/lithic/models.rb +10 -0
- data/lib/lithic/resources/webhooks.rb +1 -1
- data/lib/lithic/version.rb +1 -1
- data/lib/lithic.rb +5 -0
- data/rbi/lithic/models/auth_rules/rule_feature.rbi +686 -2
- data/rbi/lithic/models/auth_rules/typescript_code_parameters.rbi +15 -3
- data/rbi/lithic/models/claim_created_webhook_event.rbi +386 -0
- data/rbi/lithic/models/claim_document_accepted_webhook_event.rbi +315 -0
- data/rbi/lithic/models/claim_document_rejected_webhook_event.rbi +315 -0
- data/rbi/lithic/models/claim_document_uploaded_webhook_event.rbi +315 -0
- data/rbi/lithic/models/claim_updated_webhook_event.rbi +386 -0
- data/rbi/lithic/models/event.rbi +46 -0
- data/rbi/lithic/models/event_list_params.rbi +34 -0
- data/rbi/lithic/models/event_subscription.rbi +34 -0
- data/rbi/lithic/models/events/subscription_create_params.rbi +34 -0
- data/rbi/lithic/models/events/subscription_send_simulated_example_params.rbi +25 -0
- data/rbi/lithic/models/events/subscription_update_params.rbi +34 -0
- data/rbi/lithic/models/parsed_webhook_event.rbi +5 -0
- data/rbi/lithic/models.rbi +13 -0
- data/rbi/lithic/resources/webhooks.rbi +5 -0
- data/sig/lithic/models/auth_rules/rule_feature.rbs +252 -0
- data/sig/lithic/models/claim_created_webhook_event.rbs +169 -0
- data/sig/lithic/models/claim_document_accepted_webhook_event.rbs +131 -0
- data/sig/lithic/models/claim_document_rejected_webhook_event.rbs +131 -0
- data/sig/lithic/models/claim_document_uploaded_webhook_event.rbs +131 -0
- data/sig/lithic/models/claim_updated_webhook_event.rbs +169 -0
- data/sig/lithic/models/event.rbs +10 -0
- data/sig/lithic/models/event_list_params.rbs +10 -0
- data/sig/lithic/models/event_subscription.rbs +10 -0
- data/sig/lithic/models/events/subscription_create_params.rbs +10 -0
- data/sig/lithic/models/events/subscription_send_simulated_example_params.rbs +10 -0
- data/sig/lithic/models/events/subscription_update_params.rbs +10 -0
- data/sig/lithic/models/parsed_webhook_event.rbs +5 -0
- data/sig/lithic/models.rbs +10 -0
- data/sig/lithic/resources/webhooks.rbs +5 -0
- metadata +17 -2
|
@@ -0,0 +1,175 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Lithic
|
|
4
|
+
module Models
|
|
5
|
+
class ClaimDocumentAcceptedWebhookEvent < Lithic::Internal::Type::BaseModel
|
|
6
|
+
# @!attribute token
|
|
7
|
+
# Unique identifier for the document, in UUID format
|
|
8
|
+
#
|
|
9
|
+
# @return [String]
|
|
10
|
+
required :token, String
|
|
11
|
+
|
|
12
|
+
# @!attribute created
|
|
13
|
+
# When the document was created
|
|
14
|
+
#
|
|
15
|
+
# @return [Time]
|
|
16
|
+
required :created, Time
|
|
17
|
+
|
|
18
|
+
# @!attribute download_url
|
|
19
|
+
# Presigned URL for downloading the uploaded document. Available once the document
|
|
20
|
+
# is being validated or has been accepted (`VALIDATING` or `ACCEPTED`)
|
|
21
|
+
#
|
|
22
|
+
# @return [String, nil]
|
|
23
|
+
required :download_url, String, nil?: true
|
|
24
|
+
|
|
25
|
+
# @!attribute download_url_expires_at
|
|
26
|
+
# When the download URL expires
|
|
27
|
+
#
|
|
28
|
+
# @return [Time, nil]
|
|
29
|
+
required :download_url_expires_at, Time, nil?: true
|
|
30
|
+
|
|
31
|
+
# @!attribute event_type
|
|
32
|
+
# The type of event that occurred.
|
|
33
|
+
#
|
|
34
|
+
# @return [Symbol, :"claim_document.accepted"]
|
|
35
|
+
required :event_type, const: :"claim_document.accepted"
|
|
36
|
+
|
|
37
|
+
# @!attribute failure_reason
|
|
38
|
+
# Reason the document failed validation. Null unless `status` is `REJECTED`
|
|
39
|
+
#
|
|
40
|
+
# @return [Symbol, Lithic::Models::ClaimDocumentAcceptedWebhookEvent::FailureReason, nil]
|
|
41
|
+
required :failure_reason,
|
|
42
|
+
enum: -> { Lithic::ClaimDocumentAcceptedWebhookEvent::FailureReason },
|
|
43
|
+
nil?: true
|
|
44
|
+
|
|
45
|
+
# @!attribute name
|
|
46
|
+
# Name provided when the upload intent was created
|
|
47
|
+
#
|
|
48
|
+
# @return [String]
|
|
49
|
+
required :name, String
|
|
50
|
+
|
|
51
|
+
# @!attribute requirement_id
|
|
52
|
+
# Identifier of the document requirement this document satisfies. Null for
|
|
53
|
+
# supplemental documents not tied to a specific requirement
|
|
54
|
+
#
|
|
55
|
+
# @return [String, nil]
|
|
56
|
+
required :requirement_id, String, nil?: true
|
|
57
|
+
|
|
58
|
+
# @!attribute status
|
|
59
|
+
# Current validation status of the document
|
|
60
|
+
#
|
|
61
|
+
# @return [Symbol, Lithic::Models::ClaimDocumentAcceptedWebhookEvent::Status]
|
|
62
|
+
required :status, enum: -> { Lithic::ClaimDocumentAcceptedWebhookEvent::Status }
|
|
63
|
+
|
|
64
|
+
# @!attribute updated
|
|
65
|
+
# When the document was last updated
|
|
66
|
+
#
|
|
67
|
+
# @return [Time]
|
|
68
|
+
required :updated, Time
|
|
69
|
+
|
|
70
|
+
# @!attribute upload_constraints
|
|
71
|
+
# Constraints that an uploaded file must satisfy.
|
|
72
|
+
#
|
|
73
|
+
# @return [Lithic::Models::ClaimDocumentAcceptedWebhookEvent::UploadConstraints, nil]
|
|
74
|
+
required :upload_constraints,
|
|
75
|
+
-> { Lithic::ClaimDocumentAcceptedWebhookEvent::UploadConstraints },
|
|
76
|
+
nil?: true
|
|
77
|
+
|
|
78
|
+
# @!attribute upload_url
|
|
79
|
+
# Presigned URL for uploading the file via HTTP PUT. Null after the upload window
|
|
80
|
+
# expires or after the document has been validated
|
|
81
|
+
#
|
|
82
|
+
# @return [String, nil]
|
|
83
|
+
required :upload_url, String, nil?: true
|
|
84
|
+
|
|
85
|
+
# @!attribute upload_url_expires_at
|
|
86
|
+
# When the upload URL expires
|
|
87
|
+
#
|
|
88
|
+
# @return [Time, nil]
|
|
89
|
+
required :upload_url_expires_at, Time, nil?: true
|
|
90
|
+
|
|
91
|
+
# @!method initialize(token:, created:, download_url:, download_url_expires_at:, failure_reason:, name:, requirement_id:, status:, updated:, upload_constraints:, upload_url:, upload_url_expires_at:, event_type: :"claim_document.accepted")
|
|
92
|
+
# Some parameter documentations has been truncated, see
|
|
93
|
+
# {Lithic::Models::ClaimDocumentAcceptedWebhookEvent} for more details.
|
|
94
|
+
#
|
|
95
|
+
# @param token [String] Unique identifier for the document, in UUID format
|
|
96
|
+
#
|
|
97
|
+
# @param created [Time] When the document was created
|
|
98
|
+
#
|
|
99
|
+
# @param download_url [String, nil] Presigned URL for downloading the uploaded document. Available once the document
|
|
100
|
+
#
|
|
101
|
+
# @param download_url_expires_at [Time, nil] When the download URL expires
|
|
102
|
+
#
|
|
103
|
+
# @param failure_reason [Symbol, Lithic::Models::ClaimDocumentAcceptedWebhookEvent::FailureReason, nil] Reason the document failed validation. Null unless `status` is `REJECTED`
|
|
104
|
+
#
|
|
105
|
+
# @param name [String] Name provided when the upload intent was created
|
|
106
|
+
#
|
|
107
|
+
# @param requirement_id [String, nil] Identifier of the document requirement this document satisfies. Null for supplem
|
|
108
|
+
#
|
|
109
|
+
# @param status [Symbol, Lithic::Models::ClaimDocumentAcceptedWebhookEvent::Status] Current validation status of the document
|
|
110
|
+
#
|
|
111
|
+
# @param updated [Time] When the document was last updated
|
|
112
|
+
#
|
|
113
|
+
# @param upload_constraints [Lithic::Models::ClaimDocumentAcceptedWebhookEvent::UploadConstraints, nil] Constraints that an uploaded file must satisfy.
|
|
114
|
+
#
|
|
115
|
+
# @param upload_url [String, nil] Presigned URL for uploading the file via HTTP PUT. Null after the upload window
|
|
116
|
+
#
|
|
117
|
+
# @param upload_url_expires_at [Time, nil] When the upload URL expires
|
|
118
|
+
#
|
|
119
|
+
# @param event_type [Symbol, :"claim_document.accepted"] The type of event that occurred.
|
|
120
|
+
|
|
121
|
+
# Reason the document failed validation. Null unless `status` is `REJECTED`
|
|
122
|
+
#
|
|
123
|
+
# @see Lithic::Models::ClaimDocumentAcceptedWebhookEvent#failure_reason
|
|
124
|
+
module FailureReason
|
|
125
|
+
extend Lithic::Internal::Type::Enum
|
|
126
|
+
|
|
127
|
+
INVALID_MIME_TYPE = :INVALID_MIME_TYPE
|
|
128
|
+
FILE_TOO_LARGE = :FILE_TOO_LARGE
|
|
129
|
+
FILE_EMPTY = :FILE_EMPTY
|
|
130
|
+
CORRUPT_FILE = :CORRUPT_FILE
|
|
131
|
+
OTHER = :OTHER
|
|
132
|
+
|
|
133
|
+
# @!method self.values
|
|
134
|
+
# @return [Array<Symbol>]
|
|
135
|
+
end
|
|
136
|
+
|
|
137
|
+
# Current validation status of the document
|
|
138
|
+
#
|
|
139
|
+
# @see Lithic::Models::ClaimDocumentAcceptedWebhookEvent#status
|
|
140
|
+
module Status
|
|
141
|
+
extend Lithic::Internal::Type::Enum
|
|
142
|
+
|
|
143
|
+
PENDING = :PENDING
|
|
144
|
+
VALIDATING = :VALIDATING
|
|
145
|
+
ACCEPTED = :ACCEPTED
|
|
146
|
+
REJECTED = :REJECTED
|
|
147
|
+
|
|
148
|
+
# @!method self.values
|
|
149
|
+
# @return [Array<Symbol>]
|
|
150
|
+
end
|
|
151
|
+
|
|
152
|
+
# @see Lithic::Models::ClaimDocumentAcceptedWebhookEvent#upload_constraints
|
|
153
|
+
class UploadConstraints < Lithic::Internal::Type::BaseModel
|
|
154
|
+
# @!attribute accepted_mime_types
|
|
155
|
+
# MIME types accepted for upload
|
|
156
|
+
#
|
|
157
|
+
# @return [Array<String>]
|
|
158
|
+
required :accepted_mime_types, Lithic::Internal::Type::ArrayOf[String]
|
|
159
|
+
|
|
160
|
+
# @!attribute max_size_bytes
|
|
161
|
+
# Maximum file size in bytes. Null if there is no enforced size limit
|
|
162
|
+
#
|
|
163
|
+
# @return [Integer, nil]
|
|
164
|
+
required :max_size_bytes, Integer, nil?: true
|
|
165
|
+
|
|
166
|
+
# @!method initialize(accepted_mime_types:, max_size_bytes:)
|
|
167
|
+
# Constraints that an uploaded file must satisfy.
|
|
168
|
+
#
|
|
169
|
+
# @param accepted_mime_types [Array<String>] MIME types accepted for upload
|
|
170
|
+
#
|
|
171
|
+
# @param max_size_bytes [Integer, nil] Maximum file size in bytes. Null if there is no enforced size limit
|
|
172
|
+
end
|
|
173
|
+
end
|
|
174
|
+
end
|
|
175
|
+
end
|
|
@@ -0,0 +1,175 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Lithic
|
|
4
|
+
module Models
|
|
5
|
+
class ClaimDocumentRejectedWebhookEvent < Lithic::Internal::Type::BaseModel
|
|
6
|
+
# @!attribute token
|
|
7
|
+
# Unique identifier for the document, in UUID format
|
|
8
|
+
#
|
|
9
|
+
# @return [String]
|
|
10
|
+
required :token, String
|
|
11
|
+
|
|
12
|
+
# @!attribute created
|
|
13
|
+
# When the document was created
|
|
14
|
+
#
|
|
15
|
+
# @return [Time]
|
|
16
|
+
required :created, Time
|
|
17
|
+
|
|
18
|
+
# @!attribute download_url
|
|
19
|
+
# Presigned URL for downloading the uploaded document. Available once the document
|
|
20
|
+
# is being validated or has been accepted (`VALIDATING` or `ACCEPTED`)
|
|
21
|
+
#
|
|
22
|
+
# @return [String, nil]
|
|
23
|
+
required :download_url, String, nil?: true
|
|
24
|
+
|
|
25
|
+
# @!attribute download_url_expires_at
|
|
26
|
+
# When the download URL expires
|
|
27
|
+
#
|
|
28
|
+
# @return [Time, nil]
|
|
29
|
+
required :download_url_expires_at, Time, nil?: true
|
|
30
|
+
|
|
31
|
+
# @!attribute event_type
|
|
32
|
+
# The type of event that occurred.
|
|
33
|
+
#
|
|
34
|
+
# @return [Symbol, :"claim_document.rejected"]
|
|
35
|
+
required :event_type, const: :"claim_document.rejected"
|
|
36
|
+
|
|
37
|
+
# @!attribute failure_reason
|
|
38
|
+
# Reason the document failed validation. Null unless `status` is `REJECTED`
|
|
39
|
+
#
|
|
40
|
+
# @return [Symbol, Lithic::Models::ClaimDocumentRejectedWebhookEvent::FailureReason, nil]
|
|
41
|
+
required :failure_reason,
|
|
42
|
+
enum: -> { Lithic::ClaimDocumentRejectedWebhookEvent::FailureReason },
|
|
43
|
+
nil?: true
|
|
44
|
+
|
|
45
|
+
# @!attribute name
|
|
46
|
+
# Name provided when the upload intent was created
|
|
47
|
+
#
|
|
48
|
+
# @return [String]
|
|
49
|
+
required :name, String
|
|
50
|
+
|
|
51
|
+
# @!attribute requirement_id
|
|
52
|
+
# Identifier of the document requirement this document satisfies. Null for
|
|
53
|
+
# supplemental documents not tied to a specific requirement
|
|
54
|
+
#
|
|
55
|
+
# @return [String, nil]
|
|
56
|
+
required :requirement_id, String, nil?: true
|
|
57
|
+
|
|
58
|
+
# @!attribute status
|
|
59
|
+
# Current validation status of the document
|
|
60
|
+
#
|
|
61
|
+
# @return [Symbol, Lithic::Models::ClaimDocumentRejectedWebhookEvent::Status]
|
|
62
|
+
required :status, enum: -> { Lithic::ClaimDocumentRejectedWebhookEvent::Status }
|
|
63
|
+
|
|
64
|
+
# @!attribute updated
|
|
65
|
+
# When the document was last updated
|
|
66
|
+
#
|
|
67
|
+
# @return [Time]
|
|
68
|
+
required :updated, Time
|
|
69
|
+
|
|
70
|
+
# @!attribute upload_constraints
|
|
71
|
+
# Constraints that an uploaded file must satisfy.
|
|
72
|
+
#
|
|
73
|
+
# @return [Lithic::Models::ClaimDocumentRejectedWebhookEvent::UploadConstraints, nil]
|
|
74
|
+
required :upload_constraints,
|
|
75
|
+
-> { Lithic::ClaimDocumentRejectedWebhookEvent::UploadConstraints },
|
|
76
|
+
nil?: true
|
|
77
|
+
|
|
78
|
+
# @!attribute upload_url
|
|
79
|
+
# Presigned URL for uploading the file via HTTP PUT. Null after the upload window
|
|
80
|
+
# expires or after the document has been validated
|
|
81
|
+
#
|
|
82
|
+
# @return [String, nil]
|
|
83
|
+
required :upload_url, String, nil?: true
|
|
84
|
+
|
|
85
|
+
# @!attribute upload_url_expires_at
|
|
86
|
+
# When the upload URL expires
|
|
87
|
+
#
|
|
88
|
+
# @return [Time, nil]
|
|
89
|
+
required :upload_url_expires_at, Time, nil?: true
|
|
90
|
+
|
|
91
|
+
# @!method initialize(token:, created:, download_url:, download_url_expires_at:, failure_reason:, name:, requirement_id:, status:, updated:, upload_constraints:, upload_url:, upload_url_expires_at:, event_type: :"claim_document.rejected")
|
|
92
|
+
# Some parameter documentations has been truncated, see
|
|
93
|
+
# {Lithic::Models::ClaimDocumentRejectedWebhookEvent} for more details.
|
|
94
|
+
#
|
|
95
|
+
# @param token [String] Unique identifier for the document, in UUID format
|
|
96
|
+
#
|
|
97
|
+
# @param created [Time] When the document was created
|
|
98
|
+
#
|
|
99
|
+
# @param download_url [String, nil] Presigned URL for downloading the uploaded document. Available once the document
|
|
100
|
+
#
|
|
101
|
+
# @param download_url_expires_at [Time, nil] When the download URL expires
|
|
102
|
+
#
|
|
103
|
+
# @param failure_reason [Symbol, Lithic::Models::ClaimDocumentRejectedWebhookEvent::FailureReason, nil] Reason the document failed validation. Null unless `status` is `REJECTED`
|
|
104
|
+
#
|
|
105
|
+
# @param name [String] Name provided when the upload intent was created
|
|
106
|
+
#
|
|
107
|
+
# @param requirement_id [String, nil] Identifier of the document requirement this document satisfies. Null for supplem
|
|
108
|
+
#
|
|
109
|
+
# @param status [Symbol, Lithic::Models::ClaimDocumentRejectedWebhookEvent::Status] Current validation status of the document
|
|
110
|
+
#
|
|
111
|
+
# @param updated [Time] When the document was last updated
|
|
112
|
+
#
|
|
113
|
+
# @param upload_constraints [Lithic::Models::ClaimDocumentRejectedWebhookEvent::UploadConstraints, nil] Constraints that an uploaded file must satisfy.
|
|
114
|
+
#
|
|
115
|
+
# @param upload_url [String, nil] Presigned URL for uploading the file via HTTP PUT. Null after the upload window
|
|
116
|
+
#
|
|
117
|
+
# @param upload_url_expires_at [Time, nil] When the upload URL expires
|
|
118
|
+
#
|
|
119
|
+
# @param event_type [Symbol, :"claim_document.rejected"] The type of event that occurred.
|
|
120
|
+
|
|
121
|
+
# Reason the document failed validation. Null unless `status` is `REJECTED`
|
|
122
|
+
#
|
|
123
|
+
# @see Lithic::Models::ClaimDocumentRejectedWebhookEvent#failure_reason
|
|
124
|
+
module FailureReason
|
|
125
|
+
extend Lithic::Internal::Type::Enum
|
|
126
|
+
|
|
127
|
+
INVALID_MIME_TYPE = :INVALID_MIME_TYPE
|
|
128
|
+
FILE_TOO_LARGE = :FILE_TOO_LARGE
|
|
129
|
+
FILE_EMPTY = :FILE_EMPTY
|
|
130
|
+
CORRUPT_FILE = :CORRUPT_FILE
|
|
131
|
+
OTHER = :OTHER
|
|
132
|
+
|
|
133
|
+
# @!method self.values
|
|
134
|
+
# @return [Array<Symbol>]
|
|
135
|
+
end
|
|
136
|
+
|
|
137
|
+
# Current validation status of the document
|
|
138
|
+
#
|
|
139
|
+
# @see Lithic::Models::ClaimDocumentRejectedWebhookEvent#status
|
|
140
|
+
module Status
|
|
141
|
+
extend Lithic::Internal::Type::Enum
|
|
142
|
+
|
|
143
|
+
PENDING = :PENDING
|
|
144
|
+
VALIDATING = :VALIDATING
|
|
145
|
+
ACCEPTED = :ACCEPTED
|
|
146
|
+
REJECTED = :REJECTED
|
|
147
|
+
|
|
148
|
+
# @!method self.values
|
|
149
|
+
# @return [Array<Symbol>]
|
|
150
|
+
end
|
|
151
|
+
|
|
152
|
+
# @see Lithic::Models::ClaimDocumentRejectedWebhookEvent#upload_constraints
|
|
153
|
+
class UploadConstraints < Lithic::Internal::Type::BaseModel
|
|
154
|
+
# @!attribute accepted_mime_types
|
|
155
|
+
# MIME types accepted for upload
|
|
156
|
+
#
|
|
157
|
+
# @return [Array<String>]
|
|
158
|
+
required :accepted_mime_types, Lithic::Internal::Type::ArrayOf[String]
|
|
159
|
+
|
|
160
|
+
# @!attribute max_size_bytes
|
|
161
|
+
# Maximum file size in bytes. Null if there is no enforced size limit
|
|
162
|
+
#
|
|
163
|
+
# @return [Integer, nil]
|
|
164
|
+
required :max_size_bytes, Integer, nil?: true
|
|
165
|
+
|
|
166
|
+
# @!method initialize(accepted_mime_types:, max_size_bytes:)
|
|
167
|
+
# Constraints that an uploaded file must satisfy.
|
|
168
|
+
#
|
|
169
|
+
# @param accepted_mime_types [Array<String>] MIME types accepted for upload
|
|
170
|
+
#
|
|
171
|
+
# @param max_size_bytes [Integer, nil] Maximum file size in bytes. Null if there is no enforced size limit
|
|
172
|
+
end
|
|
173
|
+
end
|
|
174
|
+
end
|
|
175
|
+
end
|
|
@@ -0,0 +1,175 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Lithic
|
|
4
|
+
module Models
|
|
5
|
+
class ClaimDocumentUploadedWebhookEvent < Lithic::Internal::Type::BaseModel
|
|
6
|
+
# @!attribute token
|
|
7
|
+
# Unique identifier for the document, in UUID format
|
|
8
|
+
#
|
|
9
|
+
# @return [String]
|
|
10
|
+
required :token, String
|
|
11
|
+
|
|
12
|
+
# @!attribute created
|
|
13
|
+
# When the document was created
|
|
14
|
+
#
|
|
15
|
+
# @return [Time]
|
|
16
|
+
required :created, Time
|
|
17
|
+
|
|
18
|
+
# @!attribute download_url
|
|
19
|
+
# Presigned URL for downloading the uploaded document. Available once the document
|
|
20
|
+
# is being validated or has been accepted (`VALIDATING` or `ACCEPTED`)
|
|
21
|
+
#
|
|
22
|
+
# @return [String, nil]
|
|
23
|
+
required :download_url, String, nil?: true
|
|
24
|
+
|
|
25
|
+
# @!attribute download_url_expires_at
|
|
26
|
+
# When the download URL expires
|
|
27
|
+
#
|
|
28
|
+
# @return [Time, nil]
|
|
29
|
+
required :download_url_expires_at, Time, nil?: true
|
|
30
|
+
|
|
31
|
+
# @!attribute event_type
|
|
32
|
+
# The type of event that occurred.
|
|
33
|
+
#
|
|
34
|
+
# @return [Symbol, :"claim_document.uploaded"]
|
|
35
|
+
required :event_type, const: :"claim_document.uploaded"
|
|
36
|
+
|
|
37
|
+
# @!attribute failure_reason
|
|
38
|
+
# Reason the document failed validation. Null unless `status` is `REJECTED`
|
|
39
|
+
#
|
|
40
|
+
# @return [Symbol, Lithic::Models::ClaimDocumentUploadedWebhookEvent::FailureReason, nil]
|
|
41
|
+
required :failure_reason,
|
|
42
|
+
enum: -> { Lithic::ClaimDocumentUploadedWebhookEvent::FailureReason },
|
|
43
|
+
nil?: true
|
|
44
|
+
|
|
45
|
+
# @!attribute name
|
|
46
|
+
# Name provided when the upload intent was created
|
|
47
|
+
#
|
|
48
|
+
# @return [String]
|
|
49
|
+
required :name, String
|
|
50
|
+
|
|
51
|
+
# @!attribute requirement_id
|
|
52
|
+
# Identifier of the document requirement this document satisfies. Null for
|
|
53
|
+
# supplemental documents not tied to a specific requirement
|
|
54
|
+
#
|
|
55
|
+
# @return [String, nil]
|
|
56
|
+
required :requirement_id, String, nil?: true
|
|
57
|
+
|
|
58
|
+
# @!attribute status
|
|
59
|
+
# Current validation status of the document
|
|
60
|
+
#
|
|
61
|
+
# @return [Symbol, Lithic::Models::ClaimDocumentUploadedWebhookEvent::Status]
|
|
62
|
+
required :status, enum: -> { Lithic::ClaimDocumentUploadedWebhookEvent::Status }
|
|
63
|
+
|
|
64
|
+
# @!attribute updated
|
|
65
|
+
# When the document was last updated
|
|
66
|
+
#
|
|
67
|
+
# @return [Time]
|
|
68
|
+
required :updated, Time
|
|
69
|
+
|
|
70
|
+
# @!attribute upload_constraints
|
|
71
|
+
# Constraints that an uploaded file must satisfy.
|
|
72
|
+
#
|
|
73
|
+
# @return [Lithic::Models::ClaimDocumentUploadedWebhookEvent::UploadConstraints, nil]
|
|
74
|
+
required :upload_constraints,
|
|
75
|
+
-> { Lithic::ClaimDocumentUploadedWebhookEvent::UploadConstraints },
|
|
76
|
+
nil?: true
|
|
77
|
+
|
|
78
|
+
# @!attribute upload_url
|
|
79
|
+
# Presigned URL for uploading the file via HTTP PUT. Null after the upload window
|
|
80
|
+
# expires or after the document has been validated
|
|
81
|
+
#
|
|
82
|
+
# @return [String, nil]
|
|
83
|
+
required :upload_url, String, nil?: true
|
|
84
|
+
|
|
85
|
+
# @!attribute upload_url_expires_at
|
|
86
|
+
# When the upload URL expires
|
|
87
|
+
#
|
|
88
|
+
# @return [Time, nil]
|
|
89
|
+
required :upload_url_expires_at, Time, nil?: true
|
|
90
|
+
|
|
91
|
+
# @!method initialize(token:, created:, download_url:, download_url_expires_at:, failure_reason:, name:, requirement_id:, status:, updated:, upload_constraints:, upload_url:, upload_url_expires_at:, event_type: :"claim_document.uploaded")
|
|
92
|
+
# Some parameter documentations has been truncated, see
|
|
93
|
+
# {Lithic::Models::ClaimDocumentUploadedWebhookEvent} for more details.
|
|
94
|
+
#
|
|
95
|
+
# @param token [String] Unique identifier for the document, in UUID format
|
|
96
|
+
#
|
|
97
|
+
# @param created [Time] When the document was created
|
|
98
|
+
#
|
|
99
|
+
# @param download_url [String, nil] Presigned URL for downloading the uploaded document. Available once the document
|
|
100
|
+
#
|
|
101
|
+
# @param download_url_expires_at [Time, nil] When the download URL expires
|
|
102
|
+
#
|
|
103
|
+
# @param failure_reason [Symbol, Lithic::Models::ClaimDocumentUploadedWebhookEvent::FailureReason, nil] Reason the document failed validation. Null unless `status` is `REJECTED`
|
|
104
|
+
#
|
|
105
|
+
# @param name [String] Name provided when the upload intent was created
|
|
106
|
+
#
|
|
107
|
+
# @param requirement_id [String, nil] Identifier of the document requirement this document satisfies. Null for supplem
|
|
108
|
+
#
|
|
109
|
+
# @param status [Symbol, Lithic::Models::ClaimDocumentUploadedWebhookEvent::Status] Current validation status of the document
|
|
110
|
+
#
|
|
111
|
+
# @param updated [Time] When the document was last updated
|
|
112
|
+
#
|
|
113
|
+
# @param upload_constraints [Lithic::Models::ClaimDocumentUploadedWebhookEvent::UploadConstraints, nil] Constraints that an uploaded file must satisfy.
|
|
114
|
+
#
|
|
115
|
+
# @param upload_url [String, nil] Presigned URL for uploading the file via HTTP PUT. Null after the upload window
|
|
116
|
+
#
|
|
117
|
+
# @param upload_url_expires_at [Time, nil] When the upload URL expires
|
|
118
|
+
#
|
|
119
|
+
# @param event_type [Symbol, :"claim_document.uploaded"] The type of event that occurred.
|
|
120
|
+
|
|
121
|
+
# Reason the document failed validation. Null unless `status` is `REJECTED`
|
|
122
|
+
#
|
|
123
|
+
# @see Lithic::Models::ClaimDocumentUploadedWebhookEvent#failure_reason
|
|
124
|
+
module FailureReason
|
|
125
|
+
extend Lithic::Internal::Type::Enum
|
|
126
|
+
|
|
127
|
+
INVALID_MIME_TYPE = :INVALID_MIME_TYPE
|
|
128
|
+
FILE_TOO_LARGE = :FILE_TOO_LARGE
|
|
129
|
+
FILE_EMPTY = :FILE_EMPTY
|
|
130
|
+
CORRUPT_FILE = :CORRUPT_FILE
|
|
131
|
+
OTHER = :OTHER
|
|
132
|
+
|
|
133
|
+
# @!method self.values
|
|
134
|
+
# @return [Array<Symbol>]
|
|
135
|
+
end
|
|
136
|
+
|
|
137
|
+
# Current validation status of the document
|
|
138
|
+
#
|
|
139
|
+
# @see Lithic::Models::ClaimDocumentUploadedWebhookEvent#status
|
|
140
|
+
module Status
|
|
141
|
+
extend Lithic::Internal::Type::Enum
|
|
142
|
+
|
|
143
|
+
PENDING = :PENDING
|
|
144
|
+
VALIDATING = :VALIDATING
|
|
145
|
+
ACCEPTED = :ACCEPTED
|
|
146
|
+
REJECTED = :REJECTED
|
|
147
|
+
|
|
148
|
+
# @!method self.values
|
|
149
|
+
# @return [Array<Symbol>]
|
|
150
|
+
end
|
|
151
|
+
|
|
152
|
+
# @see Lithic::Models::ClaimDocumentUploadedWebhookEvent#upload_constraints
|
|
153
|
+
class UploadConstraints < Lithic::Internal::Type::BaseModel
|
|
154
|
+
# @!attribute accepted_mime_types
|
|
155
|
+
# MIME types accepted for upload
|
|
156
|
+
#
|
|
157
|
+
# @return [Array<String>]
|
|
158
|
+
required :accepted_mime_types, Lithic::Internal::Type::ArrayOf[String]
|
|
159
|
+
|
|
160
|
+
# @!attribute max_size_bytes
|
|
161
|
+
# Maximum file size in bytes. Null if there is no enforced size limit
|
|
162
|
+
#
|
|
163
|
+
# @return [Integer, nil]
|
|
164
|
+
required :max_size_bytes, Integer, nil?: true
|
|
165
|
+
|
|
166
|
+
# @!method initialize(accepted_mime_types:, max_size_bytes:)
|
|
167
|
+
# Constraints that an uploaded file must satisfy.
|
|
168
|
+
#
|
|
169
|
+
# @param accepted_mime_types [Array<String>] MIME types accepted for upload
|
|
170
|
+
#
|
|
171
|
+
# @param max_size_bytes [Integer, nil] Maximum file size in bytes. Null if there is no enforced size limit
|
|
172
|
+
end
|
|
173
|
+
end
|
|
174
|
+
end
|
|
175
|
+
end
|