dodopayments 2.21.0 → 2.22.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 +8 -0
- data/README.md +1 -1
- data/lib/dodopayments/models/payment.rb +5 -147
- data/lib/dodopayments/models/payment_list_params.rb +6 -2
- data/lib/dodopayments/models/payout_created_webhook_event.rb +188 -0
- data/lib/dodopayments/models/payout_failed_webhook_event.rb +188 -0
- data/lib/dodopayments/models/payout_in_progress_webhook_event.rb +188 -0
- data/lib/dodopayments/models/payout_on_hold_webhook_event.rb +188 -0
- data/lib/dodopayments/models/payout_success_webhook_event.rb +188 -0
- data/lib/dodopayments/models/unsafe_unwrap_webhook_event.rb +11 -1
- data/lib/dodopayments/models/unwrap_webhook_event.rb +11 -1
- data/lib/dodopayments/models/webhook_event_type.rb +1 -1
- data/lib/dodopayments/models/webhook_payload.rb +160 -3
- data/lib/dodopayments/models.rb +10 -0
- data/lib/dodopayments/resources/payments.rb +4 -1
- data/lib/dodopayments/resources/webhooks.rb +2 -2
- data/lib/dodopayments/version.rb +1 -1
- data/lib/dodopayments.rb +5 -0
- data/rbi/dodopayments/models/payment.rbi +6 -349
- data/rbi/dodopayments/models/payment_list_params.rbi +4 -2
- data/rbi/dodopayments/models/payout_created_webhook_event.rbi +270 -0
- data/rbi/dodopayments/models/payout_failed_webhook_event.rbi +270 -0
- data/rbi/dodopayments/models/payout_in_progress_webhook_event.rbi +272 -0
- data/rbi/dodopayments/models/payout_on_hold_webhook_event.rbi +270 -0
- data/rbi/dodopayments/models/payout_success_webhook_event.rbi +270 -0
- data/rbi/dodopayments/models/unsafe_unwrap_webhook_event.rbi +5 -0
- data/rbi/dodopayments/models/unwrap_webhook_event.rbi +5 -0
- data/rbi/dodopayments/models/webhook_event_type.rbi +2 -5
- data/rbi/dodopayments/models/webhook_payload.rbi +213 -0
- data/rbi/dodopayments/models.rbi +11 -0
- data/rbi/dodopayments/resources/payments.rbi +2 -1
- data/rbi/dodopayments/resources/webhooks.rbi +10 -0
- data/sig/dodopayments/models/payment.rbs +0 -135
- data/sig/dodopayments/models/payout_created_webhook_event.rbs +137 -0
- data/sig/dodopayments/models/payout_failed_webhook_event.rbs +137 -0
- data/sig/dodopayments/models/payout_in_progress_webhook_event.rbs +137 -0
- data/sig/dodopayments/models/payout_on_hold_webhook_event.rbs +137 -0
- data/sig/dodopayments/models/payout_success_webhook_event.rbs +137 -0
- data/sig/dodopayments/models/unsafe_unwrap_webhook_event.rbs +5 -0
- data/sig/dodopayments/models/unwrap_webhook_event.rbs +5 -0
- data/sig/dodopayments/models/webhook_event_type.rbs +2 -2
- data/sig/dodopayments/models/webhook_payload.rbs +108 -0
- data/sig/dodopayments/models.rbs +10 -0
- data/sig/dodopayments/resources/webhooks.rbs +10 -0
- metadata +17 -2
|
@@ -0,0 +1,137 @@
|
|
|
1
|
+
module Dodopayments
|
|
2
|
+
module Models
|
|
3
|
+
type payout_failed_webhook_event =
|
|
4
|
+
{
|
|
5
|
+
business_id: String,
|
|
6
|
+
data: Dodopayments::PayoutFailedWebhookEvent::Data,
|
|
7
|
+
timestamp: Time,
|
|
8
|
+
type: :"payout.failed"
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
class PayoutFailedWebhookEvent < Dodopayments::Internal::Type::BaseModel
|
|
12
|
+
attr_accessor business_id: String
|
|
13
|
+
|
|
14
|
+
attr_accessor data: Dodopayments::PayoutFailedWebhookEvent::Data
|
|
15
|
+
|
|
16
|
+
attr_accessor timestamp: Time
|
|
17
|
+
|
|
18
|
+
attr_accessor type: :"payout.failed"
|
|
19
|
+
|
|
20
|
+
def initialize: (
|
|
21
|
+
business_id: String,
|
|
22
|
+
data: Dodopayments::PayoutFailedWebhookEvent::Data,
|
|
23
|
+
timestamp: Time,
|
|
24
|
+
?type: :"payout.failed"
|
|
25
|
+
) -> void
|
|
26
|
+
|
|
27
|
+
def to_hash: -> {
|
|
28
|
+
business_id: String,
|
|
29
|
+
data: Dodopayments::PayoutFailedWebhookEvent::Data,
|
|
30
|
+
timestamp: Time,
|
|
31
|
+
type: :"payout.failed"
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
type data =
|
|
35
|
+
{
|
|
36
|
+
amount: Integer,
|
|
37
|
+
business_id: String,
|
|
38
|
+
chargebacks: Integer,
|
|
39
|
+
created_at: Time,
|
|
40
|
+
currency: Dodopayments::Models::currency,
|
|
41
|
+
fee: Integer,
|
|
42
|
+
payment_method: String,
|
|
43
|
+
payout_id: String,
|
|
44
|
+
refunds: Integer,
|
|
45
|
+
status: Dodopayments::Models::PayoutFailedWebhookEvent::Data::status,
|
|
46
|
+
tax: Integer,
|
|
47
|
+
updated_at: Time,
|
|
48
|
+
name: String?,
|
|
49
|
+
payout_document_url: String?,
|
|
50
|
+
remarks: String?
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
class Data < Dodopayments::Internal::Type::BaseModel
|
|
54
|
+
attr_accessor amount: Integer
|
|
55
|
+
|
|
56
|
+
attr_accessor business_id: String
|
|
57
|
+
|
|
58
|
+
attr_accessor chargebacks: Integer
|
|
59
|
+
|
|
60
|
+
attr_accessor created_at: Time
|
|
61
|
+
|
|
62
|
+
attr_accessor currency: Dodopayments::Models::currency
|
|
63
|
+
|
|
64
|
+
attr_accessor fee: Integer
|
|
65
|
+
|
|
66
|
+
attr_accessor payment_method: String
|
|
67
|
+
|
|
68
|
+
attr_accessor payout_id: String
|
|
69
|
+
|
|
70
|
+
attr_accessor refunds: Integer
|
|
71
|
+
|
|
72
|
+
attr_accessor status: Dodopayments::Models::PayoutFailedWebhookEvent::Data::status
|
|
73
|
+
|
|
74
|
+
attr_accessor tax: Integer
|
|
75
|
+
|
|
76
|
+
attr_accessor updated_at: Time
|
|
77
|
+
|
|
78
|
+
attr_accessor name: String?
|
|
79
|
+
|
|
80
|
+
attr_accessor payout_document_url: String?
|
|
81
|
+
|
|
82
|
+
attr_accessor remarks: String?
|
|
83
|
+
|
|
84
|
+
def initialize: (
|
|
85
|
+
amount: Integer,
|
|
86
|
+
business_id: String,
|
|
87
|
+
chargebacks: Integer,
|
|
88
|
+
created_at: Time,
|
|
89
|
+
currency: Dodopayments::Models::currency,
|
|
90
|
+
fee: Integer,
|
|
91
|
+
payment_method: String,
|
|
92
|
+
payout_id: String,
|
|
93
|
+
refunds: Integer,
|
|
94
|
+
status: Dodopayments::Models::PayoutFailedWebhookEvent::Data::status,
|
|
95
|
+
tax: Integer,
|
|
96
|
+
updated_at: Time,
|
|
97
|
+
?name: String?,
|
|
98
|
+
?payout_document_url: String?,
|
|
99
|
+
?remarks: String?
|
|
100
|
+
) -> void
|
|
101
|
+
|
|
102
|
+
def to_hash: -> {
|
|
103
|
+
amount: Integer,
|
|
104
|
+
business_id: String,
|
|
105
|
+
chargebacks: Integer,
|
|
106
|
+
created_at: Time,
|
|
107
|
+
currency: Dodopayments::Models::currency,
|
|
108
|
+
fee: Integer,
|
|
109
|
+
payment_method: String,
|
|
110
|
+
payout_id: String,
|
|
111
|
+
refunds: Integer,
|
|
112
|
+
status: Dodopayments::Models::PayoutFailedWebhookEvent::Data::status,
|
|
113
|
+
tax: Integer,
|
|
114
|
+
updated_at: Time,
|
|
115
|
+
name: String?,
|
|
116
|
+
payout_document_url: String?,
|
|
117
|
+
remarks: String?
|
|
118
|
+
}
|
|
119
|
+
|
|
120
|
+
type status =
|
|
121
|
+
:not_initiated | :in_progress | :on_hold | :failed | :success
|
|
122
|
+
|
|
123
|
+
module Status
|
|
124
|
+
extend Dodopayments::Internal::Type::Enum
|
|
125
|
+
|
|
126
|
+
NOT_INITIATED: :not_initiated
|
|
127
|
+
IN_PROGRESS: :in_progress
|
|
128
|
+
ON_HOLD: :on_hold
|
|
129
|
+
FAILED: :failed
|
|
130
|
+
SUCCESS: :success
|
|
131
|
+
|
|
132
|
+
def self?.values: -> ::Array[Dodopayments::Models::PayoutFailedWebhookEvent::Data::status]
|
|
133
|
+
end
|
|
134
|
+
end
|
|
135
|
+
end
|
|
136
|
+
end
|
|
137
|
+
end
|
|
@@ -0,0 +1,137 @@
|
|
|
1
|
+
module Dodopayments
|
|
2
|
+
module Models
|
|
3
|
+
type payout_in_progress_webhook_event =
|
|
4
|
+
{
|
|
5
|
+
business_id: String,
|
|
6
|
+
data: Dodopayments::PayoutInProgressWebhookEvent::Data,
|
|
7
|
+
timestamp: Time,
|
|
8
|
+
type: :"payout.in_progress"
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
class PayoutInProgressWebhookEvent < Dodopayments::Internal::Type::BaseModel
|
|
12
|
+
attr_accessor business_id: String
|
|
13
|
+
|
|
14
|
+
attr_accessor data: Dodopayments::PayoutInProgressWebhookEvent::Data
|
|
15
|
+
|
|
16
|
+
attr_accessor timestamp: Time
|
|
17
|
+
|
|
18
|
+
attr_accessor type: :"payout.in_progress"
|
|
19
|
+
|
|
20
|
+
def initialize: (
|
|
21
|
+
business_id: String,
|
|
22
|
+
data: Dodopayments::PayoutInProgressWebhookEvent::Data,
|
|
23
|
+
timestamp: Time,
|
|
24
|
+
?type: :"payout.in_progress"
|
|
25
|
+
) -> void
|
|
26
|
+
|
|
27
|
+
def to_hash: -> {
|
|
28
|
+
business_id: String,
|
|
29
|
+
data: Dodopayments::PayoutInProgressWebhookEvent::Data,
|
|
30
|
+
timestamp: Time,
|
|
31
|
+
type: :"payout.in_progress"
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
type data =
|
|
35
|
+
{
|
|
36
|
+
amount: Integer,
|
|
37
|
+
business_id: String,
|
|
38
|
+
chargebacks: Integer,
|
|
39
|
+
created_at: Time,
|
|
40
|
+
currency: Dodopayments::Models::currency,
|
|
41
|
+
fee: Integer,
|
|
42
|
+
payment_method: String,
|
|
43
|
+
payout_id: String,
|
|
44
|
+
refunds: Integer,
|
|
45
|
+
status: Dodopayments::Models::PayoutInProgressWebhookEvent::Data::status,
|
|
46
|
+
tax: Integer,
|
|
47
|
+
updated_at: Time,
|
|
48
|
+
name: String?,
|
|
49
|
+
payout_document_url: String?,
|
|
50
|
+
remarks: String?
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
class Data < Dodopayments::Internal::Type::BaseModel
|
|
54
|
+
attr_accessor amount: Integer
|
|
55
|
+
|
|
56
|
+
attr_accessor business_id: String
|
|
57
|
+
|
|
58
|
+
attr_accessor chargebacks: Integer
|
|
59
|
+
|
|
60
|
+
attr_accessor created_at: Time
|
|
61
|
+
|
|
62
|
+
attr_accessor currency: Dodopayments::Models::currency
|
|
63
|
+
|
|
64
|
+
attr_accessor fee: Integer
|
|
65
|
+
|
|
66
|
+
attr_accessor payment_method: String
|
|
67
|
+
|
|
68
|
+
attr_accessor payout_id: String
|
|
69
|
+
|
|
70
|
+
attr_accessor refunds: Integer
|
|
71
|
+
|
|
72
|
+
attr_accessor status: Dodopayments::Models::PayoutInProgressWebhookEvent::Data::status
|
|
73
|
+
|
|
74
|
+
attr_accessor tax: Integer
|
|
75
|
+
|
|
76
|
+
attr_accessor updated_at: Time
|
|
77
|
+
|
|
78
|
+
attr_accessor name: String?
|
|
79
|
+
|
|
80
|
+
attr_accessor payout_document_url: String?
|
|
81
|
+
|
|
82
|
+
attr_accessor remarks: String?
|
|
83
|
+
|
|
84
|
+
def initialize: (
|
|
85
|
+
amount: Integer,
|
|
86
|
+
business_id: String,
|
|
87
|
+
chargebacks: Integer,
|
|
88
|
+
created_at: Time,
|
|
89
|
+
currency: Dodopayments::Models::currency,
|
|
90
|
+
fee: Integer,
|
|
91
|
+
payment_method: String,
|
|
92
|
+
payout_id: String,
|
|
93
|
+
refunds: Integer,
|
|
94
|
+
status: Dodopayments::Models::PayoutInProgressWebhookEvent::Data::status,
|
|
95
|
+
tax: Integer,
|
|
96
|
+
updated_at: Time,
|
|
97
|
+
?name: String?,
|
|
98
|
+
?payout_document_url: String?,
|
|
99
|
+
?remarks: String?
|
|
100
|
+
) -> void
|
|
101
|
+
|
|
102
|
+
def to_hash: -> {
|
|
103
|
+
amount: Integer,
|
|
104
|
+
business_id: String,
|
|
105
|
+
chargebacks: Integer,
|
|
106
|
+
created_at: Time,
|
|
107
|
+
currency: Dodopayments::Models::currency,
|
|
108
|
+
fee: Integer,
|
|
109
|
+
payment_method: String,
|
|
110
|
+
payout_id: String,
|
|
111
|
+
refunds: Integer,
|
|
112
|
+
status: Dodopayments::Models::PayoutInProgressWebhookEvent::Data::status,
|
|
113
|
+
tax: Integer,
|
|
114
|
+
updated_at: Time,
|
|
115
|
+
name: String?,
|
|
116
|
+
payout_document_url: String?,
|
|
117
|
+
remarks: String?
|
|
118
|
+
}
|
|
119
|
+
|
|
120
|
+
type status =
|
|
121
|
+
:not_initiated | :in_progress | :on_hold | :failed | :success
|
|
122
|
+
|
|
123
|
+
module Status
|
|
124
|
+
extend Dodopayments::Internal::Type::Enum
|
|
125
|
+
|
|
126
|
+
NOT_INITIATED: :not_initiated
|
|
127
|
+
IN_PROGRESS: :in_progress
|
|
128
|
+
ON_HOLD: :on_hold
|
|
129
|
+
FAILED: :failed
|
|
130
|
+
SUCCESS: :success
|
|
131
|
+
|
|
132
|
+
def self?.values: -> ::Array[Dodopayments::Models::PayoutInProgressWebhookEvent::Data::status]
|
|
133
|
+
end
|
|
134
|
+
end
|
|
135
|
+
end
|
|
136
|
+
end
|
|
137
|
+
end
|
|
@@ -0,0 +1,137 @@
|
|
|
1
|
+
module Dodopayments
|
|
2
|
+
module Models
|
|
3
|
+
type payout_on_hold_webhook_event =
|
|
4
|
+
{
|
|
5
|
+
business_id: String,
|
|
6
|
+
data: Dodopayments::PayoutOnHoldWebhookEvent::Data,
|
|
7
|
+
timestamp: Time,
|
|
8
|
+
type: :"payout.on_hold"
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
class PayoutOnHoldWebhookEvent < Dodopayments::Internal::Type::BaseModel
|
|
12
|
+
attr_accessor business_id: String
|
|
13
|
+
|
|
14
|
+
attr_accessor data: Dodopayments::PayoutOnHoldWebhookEvent::Data
|
|
15
|
+
|
|
16
|
+
attr_accessor timestamp: Time
|
|
17
|
+
|
|
18
|
+
attr_accessor type: :"payout.on_hold"
|
|
19
|
+
|
|
20
|
+
def initialize: (
|
|
21
|
+
business_id: String,
|
|
22
|
+
data: Dodopayments::PayoutOnHoldWebhookEvent::Data,
|
|
23
|
+
timestamp: Time,
|
|
24
|
+
?type: :"payout.on_hold"
|
|
25
|
+
) -> void
|
|
26
|
+
|
|
27
|
+
def to_hash: -> {
|
|
28
|
+
business_id: String,
|
|
29
|
+
data: Dodopayments::PayoutOnHoldWebhookEvent::Data,
|
|
30
|
+
timestamp: Time,
|
|
31
|
+
type: :"payout.on_hold"
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
type data =
|
|
35
|
+
{
|
|
36
|
+
amount: Integer,
|
|
37
|
+
business_id: String,
|
|
38
|
+
chargebacks: Integer,
|
|
39
|
+
created_at: Time,
|
|
40
|
+
currency: Dodopayments::Models::currency,
|
|
41
|
+
fee: Integer,
|
|
42
|
+
payment_method: String,
|
|
43
|
+
payout_id: String,
|
|
44
|
+
refunds: Integer,
|
|
45
|
+
status: Dodopayments::Models::PayoutOnHoldWebhookEvent::Data::status,
|
|
46
|
+
tax: Integer,
|
|
47
|
+
updated_at: Time,
|
|
48
|
+
name: String?,
|
|
49
|
+
payout_document_url: String?,
|
|
50
|
+
remarks: String?
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
class Data < Dodopayments::Internal::Type::BaseModel
|
|
54
|
+
attr_accessor amount: Integer
|
|
55
|
+
|
|
56
|
+
attr_accessor business_id: String
|
|
57
|
+
|
|
58
|
+
attr_accessor chargebacks: Integer
|
|
59
|
+
|
|
60
|
+
attr_accessor created_at: Time
|
|
61
|
+
|
|
62
|
+
attr_accessor currency: Dodopayments::Models::currency
|
|
63
|
+
|
|
64
|
+
attr_accessor fee: Integer
|
|
65
|
+
|
|
66
|
+
attr_accessor payment_method: String
|
|
67
|
+
|
|
68
|
+
attr_accessor payout_id: String
|
|
69
|
+
|
|
70
|
+
attr_accessor refunds: Integer
|
|
71
|
+
|
|
72
|
+
attr_accessor status: Dodopayments::Models::PayoutOnHoldWebhookEvent::Data::status
|
|
73
|
+
|
|
74
|
+
attr_accessor tax: Integer
|
|
75
|
+
|
|
76
|
+
attr_accessor updated_at: Time
|
|
77
|
+
|
|
78
|
+
attr_accessor name: String?
|
|
79
|
+
|
|
80
|
+
attr_accessor payout_document_url: String?
|
|
81
|
+
|
|
82
|
+
attr_accessor remarks: String?
|
|
83
|
+
|
|
84
|
+
def initialize: (
|
|
85
|
+
amount: Integer,
|
|
86
|
+
business_id: String,
|
|
87
|
+
chargebacks: Integer,
|
|
88
|
+
created_at: Time,
|
|
89
|
+
currency: Dodopayments::Models::currency,
|
|
90
|
+
fee: Integer,
|
|
91
|
+
payment_method: String,
|
|
92
|
+
payout_id: String,
|
|
93
|
+
refunds: Integer,
|
|
94
|
+
status: Dodopayments::Models::PayoutOnHoldWebhookEvent::Data::status,
|
|
95
|
+
tax: Integer,
|
|
96
|
+
updated_at: Time,
|
|
97
|
+
?name: String?,
|
|
98
|
+
?payout_document_url: String?,
|
|
99
|
+
?remarks: String?
|
|
100
|
+
) -> void
|
|
101
|
+
|
|
102
|
+
def to_hash: -> {
|
|
103
|
+
amount: Integer,
|
|
104
|
+
business_id: String,
|
|
105
|
+
chargebacks: Integer,
|
|
106
|
+
created_at: Time,
|
|
107
|
+
currency: Dodopayments::Models::currency,
|
|
108
|
+
fee: Integer,
|
|
109
|
+
payment_method: String,
|
|
110
|
+
payout_id: String,
|
|
111
|
+
refunds: Integer,
|
|
112
|
+
status: Dodopayments::Models::PayoutOnHoldWebhookEvent::Data::status,
|
|
113
|
+
tax: Integer,
|
|
114
|
+
updated_at: Time,
|
|
115
|
+
name: String?,
|
|
116
|
+
payout_document_url: String?,
|
|
117
|
+
remarks: String?
|
|
118
|
+
}
|
|
119
|
+
|
|
120
|
+
type status =
|
|
121
|
+
:not_initiated | :in_progress | :on_hold | :failed | :success
|
|
122
|
+
|
|
123
|
+
module Status
|
|
124
|
+
extend Dodopayments::Internal::Type::Enum
|
|
125
|
+
|
|
126
|
+
NOT_INITIATED: :not_initiated
|
|
127
|
+
IN_PROGRESS: :in_progress
|
|
128
|
+
ON_HOLD: :on_hold
|
|
129
|
+
FAILED: :failed
|
|
130
|
+
SUCCESS: :success
|
|
131
|
+
|
|
132
|
+
def self?.values: -> ::Array[Dodopayments::Models::PayoutOnHoldWebhookEvent::Data::status]
|
|
133
|
+
end
|
|
134
|
+
end
|
|
135
|
+
end
|
|
136
|
+
end
|
|
137
|
+
end
|
|
@@ -0,0 +1,137 @@
|
|
|
1
|
+
module Dodopayments
|
|
2
|
+
module Models
|
|
3
|
+
type payout_success_webhook_event =
|
|
4
|
+
{
|
|
5
|
+
business_id: String,
|
|
6
|
+
data: Dodopayments::PayoutSuccessWebhookEvent::Data,
|
|
7
|
+
timestamp: Time,
|
|
8
|
+
type: :"payout.success"
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
class PayoutSuccessWebhookEvent < Dodopayments::Internal::Type::BaseModel
|
|
12
|
+
attr_accessor business_id: String
|
|
13
|
+
|
|
14
|
+
attr_accessor data: Dodopayments::PayoutSuccessWebhookEvent::Data
|
|
15
|
+
|
|
16
|
+
attr_accessor timestamp: Time
|
|
17
|
+
|
|
18
|
+
attr_accessor type: :"payout.success"
|
|
19
|
+
|
|
20
|
+
def initialize: (
|
|
21
|
+
business_id: String,
|
|
22
|
+
data: Dodopayments::PayoutSuccessWebhookEvent::Data,
|
|
23
|
+
timestamp: Time,
|
|
24
|
+
?type: :"payout.success"
|
|
25
|
+
) -> void
|
|
26
|
+
|
|
27
|
+
def to_hash: -> {
|
|
28
|
+
business_id: String,
|
|
29
|
+
data: Dodopayments::PayoutSuccessWebhookEvent::Data,
|
|
30
|
+
timestamp: Time,
|
|
31
|
+
type: :"payout.success"
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
type data =
|
|
35
|
+
{
|
|
36
|
+
amount: Integer,
|
|
37
|
+
business_id: String,
|
|
38
|
+
chargebacks: Integer,
|
|
39
|
+
created_at: Time,
|
|
40
|
+
currency: Dodopayments::Models::currency,
|
|
41
|
+
fee: Integer,
|
|
42
|
+
payment_method: String,
|
|
43
|
+
payout_id: String,
|
|
44
|
+
refunds: Integer,
|
|
45
|
+
status: Dodopayments::Models::PayoutSuccessWebhookEvent::Data::status,
|
|
46
|
+
tax: Integer,
|
|
47
|
+
updated_at: Time,
|
|
48
|
+
name: String?,
|
|
49
|
+
payout_document_url: String?,
|
|
50
|
+
remarks: String?
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
class Data < Dodopayments::Internal::Type::BaseModel
|
|
54
|
+
attr_accessor amount: Integer
|
|
55
|
+
|
|
56
|
+
attr_accessor business_id: String
|
|
57
|
+
|
|
58
|
+
attr_accessor chargebacks: Integer
|
|
59
|
+
|
|
60
|
+
attr_accessor created_at: Time
|
|
61
|
+
|
|
62
|
+
attr_accessor currency: Dodopayments::Models::currency
|
|
63
|
+
|
|
64
|
+
attr_accessor fee: Integer
|
|
65
|
+
|
|
66
|
+
attr_accessor payment_method: String
|
|
67
|
+
|
|
68
|
+
attr_accessor payout_id: String
|
|
69
|
+
|
|
70
|
+
attr_accessor refunds: Integer
|
|
71
|
+
|
|
72
|
+
attr_accessor status: Dodopayments::Models::PayoutSuccessWebhookEvent::Data::status
|
|
73
|
+
|
|
74
|
+
attr_accessor tax: Integer
|
|
75
|
+
|
|
76
|
+
attr_accessor updated_at: Time
|
|
77
|
+
|
|
78
|
+
attr_accessor name: String?
|
|
79
|
+
|
|
80
|
+
attr_accessor payout_document_url: String?
|
|
81
|
+
|
|
82
|
+
attr_accessor remarks: String?
|
|
83
|
+
|
|
84
|
+
def initialize: (
|
|
85
|
+
amount: Integer,
|
|
86
|
+
business_id: String,
|
|
87
|
+
chargebacks: Integer,
|
|
88
|
+
created_at: Time,
|
|
89
|
+
currency: Dodopayments::Models::currency,
|
|
90
|
+
fee: Integer,
|
|
91
|
+
payment_method: String,
|
|
92
|
+
payout_id: String,
|
|
93
|
+
refunds: Integer,
|
|
94
|
+
status: Dodopayments::Models::PayoutSuccessWebhookEvent::Data::status,
|
|
95
|
+
tax: Integer,
|
|
96
|
+
updated_at: Time,
|
|
97
|
+
?name: String?,
|
|
98
|
+
?payout_document_url: String?,
|
|
99
|
+
?remarks: String?
|
|
100
|
+
) -> void
|
|
101
|
+
|
|
102
|
+
def to_hash: -> {
|
|
103
|
+
amount: Integer,
|
|
104
|
+
business_id: String,
|
|
105
|
+
chargebacks: Integer,
|
|
106
|
+
created_at: Time,
|
|
107
|
+
currency: Dodopayments::Models::currency,
|
|
108
|
+
fee: Integer,
|
|
109
|
+
payment_method: String,
|
|
110
|
+
payout_id: String,
|
|
111
|
+
refunds: Integer,
|
|
112
|
+
status: Dodopayments::Models::PayoutSuccessWebhookEvent::Data::status,
|
|
113
|
+
tax: Integer,
|
|
114
|
+
updated_at: Time,
|
|
115
|
+
name: String?,
|
|
116
|
+
payout_document_url: String?,
|
|
117
|
+
remarks: String?
|
|
118
|
+
}
|
|
119
|
+
|
|
120
|
+
type status =
|
|
121
|
+
:not_initiated | :in_progress | :on_hold | :failed | :success
|
|
122
|
+
|
|
123
|
+
module Status
|
|
124
|
+
extend Dodopayments::Internal::Type::Enum
|
|
125
|
+
|
|
126
|
+
NOT_INITIATED: :not_initiated
|
|
127
|
+
IN_PROGRESS: :in_progress
|
|
128
|
+
ON_HOLD: :on_hold
|
|
129
|
+
FAILED: :failed
|
|
130
|
+
SUCCESS: :success
|
|
131
|
+
|
|
132
|
+
def self?.values: -> ::Array[Dodopayments::Models::PayoutSuccessWebhookEvent::Data::status]
|
|
133
|
+
end
|
|
134
|
+
end
|
|
135
|
+
end
|
|
136
|
+
end
|
|
137
|
+
end
|
|
@@ -30,6 +30,11 @@ module Dodopayments
|
|
|
30
30
|
| Dodopayments::PaymentFailedWebhookEvent
|
|
31
31
|
| Dodopayments::PaymentProcessingWebhookEvent
|
|
32
32
|
| Dodopayments::PaymentSucceededWebhookEvent
|
|
33
|
+
| Dodopayments::PayoutCreatedWebhookEvent
|
|
34
|
+
| Dodopayments::PayoutFailedWebhookEvent
|
|
35
|
+
| Dodopayments::PayoutInProgressWebhookEvent
|
|
36
|
+
| Dodopayments::PayoutOnHoldWebhookEvent
|
|
37
|
+
| Dodopayments::PayoutSuccessWebhookEvent
|
|
33
38
|
| Dodopayments::RefundFailedWebhookEvent
|
|
34
39
|
| Dodopayments::RefundSucceededWebhookEvent
|
|
35
40
|
| Dodopayments::SubscriptionActiveWebhookEvent
|
|
@@ -30,6 +30,11 @@ module Dodopayments
|
|
|
30
30
|
| Dodopayments::PaymentFailedWebhookEvent
|
|
31
31
|
| Dodopayments::PaymentProcessingWebhookEvent
|
|
32
32
|
| Dodopayments::PaymentSucceededWebhookEvent
|
|
33
|
+
| Dodopayments::PayoutCreatedWebhookEvent
|
|
34
|
+
| Dodopayments::PayoutFailedWebhookEvent
|
|
35
|
+
| Dodopayments::PayoutInProgressWebhookEvent
|
|
36
|
+
| Dodopayments::PayoutOnHoldWebhookEvent
|
|
37
|
+
| Dodopayments::PayoutSuccessWebhookEvent
|
|
33
38
|
| Dodopayments::RefundFailedWebhookEvent
|
|
34
39
|
| Dodopayments::RefundSucceededWebhookEvent
|
|
35
40
|
| Dodopayments::SubscriptionActiveWebhookEvent
|
|
@@ -25,7 +25,7 @@ module Dodopayments
|
|
|
25
25
|
| :"subscription.updated"
|
|
26
26
|
| :"subscription.update_payment_method"
|
|
27
27
|
| :"license_key.created"
|
|
28
|
-
| :"payout.
|
|
28
|
+
| :"payout.created"
|
|
29
29
|
| :"payout.on_hold"
|
|
30
30
|
| :"payout.in_progress"
|
|
31
31
|
| :"payout.failed"
|
|
@@ -75,7 +75,7 @@ module Dodopayments
|
|
|
75
75
|
SUBSCRIPTION_UPDATED: :"subscription.updated"
|
|
76
76
|
SUBSCRIPTION_UPDATE_PAYMENT_METHOD: :"subscription.update_payment_method"
|
|
77
77
|
LICENSE_KEY_CREATED: :"license_key.created"
|
|
78
|
-
|
|
78
|
+
PAYOUT_CREATED: :"payout.created"
|
|
79
79
|
PAYOUT_ON_HOLD: :"payout.on_hold"
|
|
80
80
|
PAYOUT_IN_PROGRESS: :"payout.in_progress"
|
|
81
81
|
PAYOUT_FAILED: :"payout.failed"
|