mollie-api-ruby 2.2.1 → 3.1.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +5 -5
- data/CHANGELOG.md +7 -0
- data/README.md +37 -8
- data/examples/apis/api_docs.rb +1 -1
- data/examples/apis/chargebacks.rb +17 -0
- data/examples/apis/connect.rb +1 -1
- data/examples/apis/customers.rb +7 -6
- data/examples/apis/invoices.rb +2 -2
- data/examples/apis/issuers.rb +2 -2
- data/examples/apis/mandates.rb +5 -5
- data/examples/apis/methods.rb +2 -2
- data/examples/apis/organizations.rb +1 -1
- data/examples/apis/payments.rb +43 -9
- data/examples/apis/permissions.rb +2 -2
- data/examples/apis/profiles.rb +7 -7
- data/examples/apis/refunds.rb +1 -1
- data/examples/apis/settlements.rb +5 -5
- data/examples/apis/subscriptions.rb +7 -7
- data/examples/config.ru +6 -7
- data/lib/{mollie/api/cacert.pem → cacert.pem} +0 -0
- data/lib/mollie-api-ruby.rb +1 -0
- data/lib/mollie.rb +39 -0
- data/lib/mollie/base.rb +91 -0
- data/lib/mollie/chargeback.rb +36 -0
- data/lib/mollie/client.rb +125 -0
- data/lib/mollie/customer.rb +36 -0
- data/lib/mollie/customer/mandate.rb +33 -0
- data/lib/mollie/customer/payment.rb +6 -0
- data/lib/mollie/customer/subscription.rb +65 -0
- data/lib/mollie/exception.rb +8 -0
- data/lib/mollie/invoice.rb +66 -0
- data/lib/mollie/issuer.rb +5 -0
- data/lib/mollie/list.rb +40 -0
- data/lib/mollie/method.rb +38 -0
- data/lib/mollie/organization.rb +24 -0
- data/lib/mollie/payment.rb +142 -0
- data/lib/mollie/payment/chargeback.rb +6 -0
- data/lib/mollie/payment/refund.rb +6 -0
- data/lib/mollie/permission.rb +26 -0
- data/lib/mollie/profile.rb +78 -0
- data/lib/mollie/profile/api_key.rb +19 -0
- data/lib/mollie/refund.rb +42 -0
- data/lib/mollie/relation.rb +36 -0
- data/lib/mollie/settlement.rb +36 -0
- data/lib/mollie/settlement/chargeback.rb +6 -0
- data/lib/mollie/settlement/payment.rb +6 -0
- data/lib/mollie/settlement/refund.rb +6 -0
- data/lib/mollie/util.rb +57 -0
- data/lib/mollie/version.rb +3 -0
- data/mollie.gemspec +2 -2
- data/test/helper.rb +5 -1
- data/test/mollie/base_test.rb +182 -0
- data/test/mollie/chargeback_test.rb +35 -0
- data/test/mollie/client_test.rb +122 -0
- data/test/mollie/customer/mandate_test.rb +43 -0
- data/test/mollie/customer/payment_test.rb +23 -0
- data/test/mollie/customer/subscription_test.rb +66 -0
- data/test/mollie/customer_test.rb +128 -0
- data/test/mollie/invoice_test.rb +55 -0
- data/test/mollie/issuer_test.rb +19 -0
- data/test/mollie/list_test.rb +40 -0
- data/test/mollie/method_test.rb +29 -0
- data/test/mollie/organization_test.rb +41 -0
- data/test/mollie/payment/chargeback_test.rb +22 -0
- data/test/mollie/payment/refund_test.rb +22 -0
- data/test/mollie/payment_test.rb +161 -0
- data/test/mollie/permission_test.rb +21 -0
- data/test/mollie/profile/apikey_test.rb +31 -0
- data/test/mollie/profile_test.rb +98 -0
- data/test/mollie/refund_test.rb +40 -0
- data/test/mollie/settlement/chargeback_test.rb +22 -0
- data/test/mollie/settlement/payment_test.rb +22 -0
- data/test/mollie/settlement/refund_test.rb +22 -0
- data/test/mollie/settlement_test.rb +156 -0
- data/website-docs/chargebacks/list-all.rb +12 -0
- data/website-docs/connect/authorize.rb +15 -0
- data/website-docs/connect/tokens.rb +14 -0
- data/website-docs/customers/create-payment.rb +13 -0
- data/website-docs/customers/create.rb +12 -0
- data/website-docs/customers/delete.rb +10 -0
- data/website-docs/customers/get.rb +10 -0
- data/website-docs/customers/list-payments.rb +10 -0
- data/website-docs/customers/list.rb +12 -0
- data/website-docs/customers/update.rb +11 -0
- data/website-docs/invoices/get.rb +10 -0
- data/website-docs/invoices/list.rb +12 -0
- data/website-docs/issuers/get.rb +10 -0
- data/website-docs/issuers/list.rb +12 -0
- data/website-docs/mandates/create.rb +16 -0
- data/website-docs/mandates/delete.rb +10 -0
- data/website-docs/mandates/get.rb +10 -0
- data/website-docs/mandates/list.rb +12 -0
- data/website-docs/methods/get.rb +10 -0
- data/website-docs/methods/list.rb +12 -0
- data/website-docs/organisations/get.rb +10 -0
- data/website-docs/payments/create-refund.rb +14 -0
- data/website-docs/payments/create.rb +16 -0
- data/website-docs/payments/delete-refund.rb +13 -0
- data/website-docs/payments/delete.rb +12 -0
- data/website-docs/payments/get-chargeback.rb +11 -0
- data/website-docs/payments/get-refund.rb +11 -0
- data/website-docs/payments/get.rb +10 -0
- data/website-docs/payments/list-chargeback.rb +13 -0
- data/website-docs/payments/list-refunds.rb +13 -0
- data/website-docs/payments/list.rb +12 -0
- data/website-docs/payments/payment-webhook.rb +21 -0
- data/website-docs/permissions/get.rb +10 -0
- data/website-docs/permissions/list.rb +12 -0
- data/website-docs/profiles/create.rb +15 -0
- data/website-docs/profiles/delete.rb +10 -0
- data/website-docs/profiles/get-key.rb +11 -0
- data/website-docs/profiles/get.rb +10 -0
- data/website-docs/profiles/list-keys.rb +13 -0
- data/website-docs/profiles/list.rb +12 -0
- data/website-docs/profiles/reset-key.rb +13 -0
- data/website-docs/profiles/update.rb +12 -0
- data/website-docs/refunds/list.rb +12 -0
- data/website-docs/settlements/get.rb +10 -0
- data/website-docs/settlements/list-chargebacks.rb +13 -0
- data/website-docs/settlements/list-payments.rb +13 -0
- data/website-docs/settlements/list-refunds.rb +13 -0
- data/website-docs/settlements/list.rb +12 -0
- data/website-docs/settlements/next.rb +9 -0
- data/website-docs/settlements/open.rb +9 -0
- data/website-docs/subscriptions/create.rb +14 -0
- data/website-docs/subscriptions/delete.rb +10 -0
- data/website-docs/subscriptions/get.rb +10 -0
- data/website-docs/subscriptions/list.rb +12 -0
- metadata +134 -104
- data/lib/mollie/api/client.rb +0 -161
- data/lib/mollie/api/client/version.rb +0 -7
- data/lib/mollie/api/exception.rb +0 -10
- data/lib/mollie/api/object/base.rb +0 -18
- data/lib/mollie/api/object/customer.rb +0 -28
- data/lib/mollie/api/object/customer/mandate.rb +0 -37
- data/lib/mollie/api/object/customer/subscription.rb +0 -69
- data/lib/mollie/api/object/invoice.rb +0 -70
- data/lib/mollie/api/object/issuer.rb +0 -9
- data/lib/mollie/api/object/list.rb +0 -44
- data/lib/mollie/api/object/method.rb +0 -42
- data/lib/mollie/api/object/organization.rb +0 -28
- data/lib/mollie/api/object/payment.rb +0 -137
- data/lib/mollie/api/object/payment/refund.rb +0 -47
- data/lib/mollie/api/object/permission.rb +0 -12
- data/lib/mollie/api/object/profile.rb +0 -78
- data/lib/mollie/api/object/profile/apikey.rb +0 -23
- data/lib/mollie/api/object/settlement.rb +0 -32
- data/lib/mollie/api/resource/base.rb +0 -53
- data/lib/mollie/api/resource/customers.rb +0 -11
- data/lib/mollie/api/resource/customers/mandates.rb +0 -27
- data/lib/mollie/api/resource/customers/payments.rb +0 -27
- data/lib/mollie/api/resource/customers/subscriptions.rb +0 -27
- data/lib/mollie/api/resource/invoices.rb +0 -11
- data/lib/mollie/api/resource/issuers.rb +0 -11
- data/lib/mollie/api/resource/methods.rb +0 -11
- data/lib/mollie/api/resource/organizations.rb +0 -11
- data/lib/mollie/api/resource/payments.rb +0 -11
- data/lib/mollie/api/resource/payments/refunds.rb +0 -27
- data/lib/mollie/api/resource/permissions.rb +0 -31
- data/lib/mollie/api/resource/profiles.rb +0 -11
- data/lib/mollie/api/resource/profiles/apikeys.rb +0 -33
- data/lib/mollie/api/resource/refunds.rb +0 -11
- data/lib/mollie/api/resource/settlements.rb +0 -19
- data/lib/mollie/api/resource/settlements/payments.rb +0 -27
- data/lib/mollie/api/util.rb +0 -53
- data/test/mollie/api/client_test.rb +0 -111
- data/test/mollie/api/object/base_test.rb +0 -21
- data/test/mollie/api/object/customer/mandate_test.rb +0 -47
- data/test/mollie/api/object/customer/subscription_test.rb +0 -70
- data/test/mollie/api/object/customer_test.rb +0 -35
- data/test/mollie/api/object/invoice_test.rb +0 -59
- data/test/mollie/api/object/issuer_test.rb +0 -23
- data/test/mollie/api/object/list_test.rb +0 -44
- data/test/mollie/api/object/method_test.rb +0 -33
- data/test/mollie/api/object/organization_test.rb +0 -45
- data/test/mollie/api/object/payment/refund_test.rb +0 -46
- data/test/mollie/api/object/payment_test.rb +0 -106
- data/test/mollie/api/object/permission_test.rb +0 -25
- data/test/mollie/api/object/profile/apikey_test.rb +0 -35
- data/test/mollie/api/object/profile_test.rb +0 -72
- data/test/mollie/api/object/settlement_test.rb +0 -140
- data/test/mollie/api/resource/base_test.rb +0 -83
- data/test/mollie/api/resource/customers/mandates_test.rb +0 -23
- data/test/mollie/api/resource/customers/payments_test.rb +0 -23
- data/test/mollie/api/resource/customers/subscriptions_test.rb +0 -23
- data/test/mollie/api/resource/customers_test.rb +0 -13
- data/test/mollie/api/resource/invoices_test.rb +0 -13
- data/test/mollie/api/resource/issuers_test.rb +0 -13
- data/test/mollie/api/resource/methods_test.rb +0 -13
- data/test/mollie/api/resource/organizations_test.rb +0 -13
- data/test/mollie/api/resource/payments/refunds_test.rb +0 -23
- data/test/mollie/api/resource/payments_test.rb +0 -13
- data/test/mollie/api/resource/permissions_test.rb +0 -13
- data/test/mollie/api/resource/profiles/apikeys_test.rb +0 -23
- data/test/mollie/api/resource/profiles_test.rb +0 -13
- data/test/mollie/api/resource/settlements_test.rb +0 -13
- data/test/mollie/api/util_test.rb +0 -47
@@ -1,47 +0,0 @@
|
|
1
|
-
module Mollie
|
2
|
-
module API
|
3
|
-
module Object
|
4
|
-
class Payment
|
5
|
-
class Refund < Base
|
6
|
-
STATUS_QUEUED = "queued"
|
7
|
-
STATUS_PENDING = "pending"
|
8
|
-
STATUS_PROCESSING = "processing"
|
9
|
-
STATUS_REFUNDED = "refunded"
|
10
|
-
|
11
|
-
attr_accessor :id,
|
12
|
-
:payment,
|
13
|
-
:amount,
|
14
|
-
:status,
|
15
|
-
:refunded_datetime
|
16
|
-
def queued?
|
17
|
-
status == STATUS_QUEUED
|
18
|
-
end
|
19
|
-
|
20
|
-
def pending?
|
21
|
-
status == STATUS_PENDING
|
22
|
-
end
|
23
|
-
|
24
|
-
def processing?
|
25
|
-
status == STATUS_PROCESSING
|
26
|
-
end
|
27
|
-
|
28
|
-
def refunded?
|
29
|
-
status == STATUS_REFUNDED
|
30
|
-
end
|
31
|
-
|
32
|
-
def refunded_datetime=(refunded_datetime)
|
33
|
-
@refunded_datetime = Time.parse(refunded_datetime) rescue nil
|
34
|
-
end
|
35
|
-
|
36
|
-
def amount=(amount)
|
37
|
-
@amount = BigDecimal.new(amount.to_s) if amount
|
38
|
-
end
|
39
|
-
|
40
|
-
def payment=(payment)
|
41
|
-
@payment = Payment.new(payment)
|
42
|
-
end
|
43
|
-
end
|
44
|
-
end
|
45
|
-
end
|
46
|
-
end
|
47
|
-
end
|
@@ -1,78 +0,0 @@
|
|
1
|
-
module Mollie
|
2
|
-
module API
|
3
|
-
module Object
|
4
|
-
class Profile < Base
|
5
|
-
CATEGORY_CODE_GENERAL_MERCHANDISE = 5399
|
6
|
-
CATEGORY_CODE_ELECTRONICS_COMPUTERS_AND_SOFTWARE = 5732
|
7
|
-
CATEGORY_CODE_TRAVEL_RENTAL_AND_TRANSPORTATION = 4121
|
8
|
-
CATEGORY_CODE_FINANCIAL_SERVICES = 6012
|
9
|
-
CATEGORY_CODE_FOOD_AND_DRINKS = 5499
|
10
|
-
CATEGORY_CODE_EVENTS_FESTIVALS_AND_RECREATION = 7999
|
11
|
-
CATEGORY_CODE_BOOKS_MAGAZINES_AND_NEWSPAPERS = 5192
|
12
|
-
CATEGORY_CODE_PERSONAL_SERVICES = 7299
|
13
|
-
CATEGORY_CODE_CHARITY_AND_DONATIONS = 8398
|
14
|
-
CATEGORY_CODE_OTHER = 0
|
15
|
-
|
16
|
-
STATUS_UNVERIFIED = "unverified"
|
17
|
-
STATUS_VERIFIED = "verified"
|
18
|
-
STATUS_BLOCKED = "blocked"
|
19
|
-
|
20
|
-
REVIEW_STATUS_PENDING = "pending"
|
21
|
-
REVIEW_STATUS_REJECTED = "rejected"
|
22
|
-
|
23
|
-
attr_accessor :id,
|
24
|
-
:mode,
|
25
|
-
:name,
|
26
|
-
:website,
|
27
|
-
:email,
|
28
|
-
:phone,
|
29
|
-
:category_code,
|
30
|
-
:status,
|
31
|
-
:review,
|
32
|
-
:created_datetime,
|
33
|
-
:updated_datetime,
|
34
|
-
:links
|
35
|
-
|
36
|
-
def unverified?
|
37
|
-
status == STATUS_UNVERIFIED
|
38
|
-
end
|
39
|
-
|
40
|
-
def verified?
|
41
|
-
status == STATUS_VERIFIED
|
42
|
-
end
|
43
|
-
|
44
|
-
def blocked?
|
45
|
-
status == STATUS_BLOCKED
|
46
|
-
end
|
47
|
-
|
48
|
-
def review=(review)
|
49
|
-
@review = OpenStruct.new(review) if review.is_a?(Hash)
|
50
|
-
end
|
51
|
-
|
52
|
-
def review_pending?
|
53
|
-
@review && @review.status == REVIEW_STATUS_PENDING
|
54
|
-
end
|
55
|
-
|
56
|
-
def review_rejected?
|
57
|
-
@review && @review.status == REVIEW_STATUS_REJECTED
|
58
|
-
end
|
59
|
-
|
60
|
-
def created_datetime=(created_datetime)
|
61
|
-
@created_datetime = Time.parse(created_datetime.to_s) rescue nil
|
62
|
-
end
|
63
|
-
|
64
|
-
def updated_datetime=(updated_datetime)
|
65
|
-
@updated_datetime = Time.parse(updated_datetime.to_s) rescue nil
|
66
|
-
end
|
67
|
-
|
68
|
-
def apikeys
|
69
|
-
links && links['apikeys']
|
70
|
-
end
|
71
|
-
|
72
|
-
def checkout_preview_url
|
73
|
-
links && links['checkout_preview_url']
|
74
|
-
end
|
75
|
-
end
|
76
|
-
end
|
77
|
-
end
|
78
|
-
end
|
@@ -1,23 +0,0 @@
|
|
1
|
-
module Mollie
|
2
|
-
module API
|
3
|
-
module Object
|
4
|
-
class Profile
|
5
|
-
class ApiKey < Base
|
6
|
-
attr_accessor :id, :key, :created_datetime
|
7
|
-
|
8
|
-
def testmode?
|
9
|
-
id == Mollie::API::Client::MODE_TEST
|
10
|
-
end
|
11
|
-
|
12
|
-
def livemode?
|
13
|
-
id == Mollie::API::Client::MODE_LIVE
|
14
|
-
end
|
15
|
-
|
16
|
-
def created_datetime=(created_datetime)
|
17
|
-
@created_datetime = Time.parse(created_datetime)
|
18
|
-
end
|
19
|
-
end
|
20
|
-
end
|
21
|
-
end
|
22
|
-
end
|
23
|
-
end
|
@@ -1,32 +0,0 @@
|
|
1
|
-
module Mollie
|
2
|
-
module API
|
3
|
-
module Object
|
4
|
-
class Settlement < Base
|
5
|
-
attr_accessor :id,
|
6
|
-
:reference,
|
7
|
-
:settled_datetime,
|
8
|
-
:amount,
|
9
|
-
:periods,
|
10
|
-
:payment_ids,
|
11
|
-
:refund_ids,
|
12
|
-
:links
|
13
|
-
|
14
|
-
def settled_datetime=(settled_datetime)
|
15
|
-
@settled_datetime = Time.parse(settled_datetime.to_s) rescue nil
|
16
|
-
end
|
17
|
-
|
18
|
-
def amount=(amount)
|
19
|
-
@amount = BigDecimal.new(amount.to_s) if amount
|
20
|
-
end
|
21
|
-
|
22
|
-
def periods=(periods)
|
23
|
-
@periods = Util.nested_openstruct(periods) if periods.is_a?(Hash)
|
24
|
-
end
|
25
|
-
|
26
|
-
def payments
|
27
|
-
links && links['payments']
|
28
|
-
end
|
29
|
-
end
|
30
|
-
end
|
31
|
-
end
|
32
|
-
end
|
@@ -1,53 +0,0 @@
|
|
1
|
-
module Mollie
|
2
|
-
module API
|
3
|
-
module Resource
|
4
|
-
class Base
|
5
|
-
def initialize(client)
|
6
|
-
@client = client
|
7
|
-
end
|
8
|
-
|
9
|
-
def resource_name
|
10
|
-
self.class.name.downcase.split("::").slice(3..-1).join "/"
|
11
|
-
end
|
12
|
-
|
13
|
-
def create(data = {})
|
14
|
-
request("POST", nil, data) { |response|
|
15
|
-
new_resource_object response
|
16
|
-
}
|
17
|
-
end
|
18
|
-
|
19
|
-
def get(id, options = {})
|
20
|
-
request("GET", id, {}, options) { |response|
|
21
|
-
new_resource_object response
|
22
|
-
}
|
23
|
-
end
|
24
|
-
|
25
|
-
def update(id, data = {})
|
26
|
-
request("POST", id, data) { |response|
|
27
|
-
new_resource_object response
|
28
|
-
}
|
29
|
-
end
|
30
|
-
|
31
|
-
def delete(id, options = {})
|
32
|
-
request "DELETE", id, options
|
33
|
-
end
|
34
|
-
|
35
|
-
def all(offset = 0, limit = 50, options = {})
|
36
|
-
request("GET", nil, {}, { offset: offset, count: limit }.merge(options)) { |response|
|
37
|
-
Object::List.new response, resource_object
|
38
|
-
}
|
39
|
-
end
|
40
|
-
|
41
|
-
def new_resource_object(response)
|
42
|
-
resource_object.new response
|
43
|
-
end
|
44
|
-
|
45
|
-
def request(method, id = 0, data = {}, query = {})
|
46
|
-
response = @client.perform_http_call method, resource_name, id, data, query
|
47
|
-
|
48
|
-
yield(response) if block_given?
|
49
|
-
end
|
50
|
-
end
|
51
|
-
end
|
52
|
-
end
|
53
|
-
end
|
@@ -1,27 +0,0 @@
|
|
1
|
-
require 'open-uri'
|
2
|
-
|
3
|
-
module Mollie
|
4
|
-
module API
|
5
|
-
module Resource
|
6
|
-
class Customers
|
7
|
-
class Mandates < Base
|
8
|
-
@customer_id = nil
|
9
|
-
|
10
|
-
def resource_object
|
11
|
-
Object::Customer::Mandate
|
12
|
-
end
|
13
|
-
|
14
|
-
def resource_name
|
15
|
-
customer_id = URI::encode(@customer_id)
|
16
|
-
"customers/#{customer_id}/mandates"
|
17
|
-
end
|
18
|
-
|
19
|
-
def with(customer_or_id)
|
20
|
-
@customer_id = customer_or_id.is_a?(Object::Customer) ? customer_or_id.id : customer_or_id
|
21
|
-
self
|
22
|
-
end
|
23
|
-
end
|
24
|
-
end
|
25
|
-
end
|
26
|
-
end
|
27
|
-
end
|
@@ -1,27 +0,0 @@
|
|
1
|
-
require 'open-uri'
|
2
|
-
|
3
|
-
module Mollie
|
4
|
-
module API
|
5
|
-
module Resource
|
6
|
-
class Customers
|
7
|
-
class Payments < Base
|
8
|
-
@customer_id = nil
|
9
|
-
|
10
|
-
def resource_object
|
11
|
-
Object::Payment
|
12
|
-
end
|
13
|
-
|
14
|
-
def resource_name
|
15
|
-
customer_id = URI::encode(@customer_id)
|
16
|
-
"customers/#{customer_id}/payments"
|
17
|
-
end
|
18
|
-
|
19
|
-
def with(customer_or_id)
|
20
|
-
@customer_id = customer_or_id.is_a?(Object::Customer) ? customer_or_id.id : customer_or_id
|
21
|
-
self
|
22
|
-
end
|
23
|
-
end
|
24
|
-
end
|
25
|
-
end
|
26
|
-
end
|
27
|
-
end
|
@@ -1,27 +0,0 @@
|
|
1
|
-
require 'open-uri'
|
2
|
-
|
3
|
-
module Mollie
|
4
|
-
module API
|
5
|
-
module Resource
|
6
|
-
class Customers
|
7
|
-
class Subscriptions < Base
|
8
|
-
@customer_id = nil
|
9
|
-
|
10
|
-
def resource_object
|
11
|
-
Object::Customer::Subscription
|
12
|
-
end
|
13
|
-
|
14
|
-
def resource_name
|
15
|
-
customer_id = URI::encode(@customer_id)
|
16
|
-
"customers/#{customer_id}/subscriptions"
|
17
|
-
end
|
18
|
-
|
19
|
-
def with(customer_or_id)
|
20
|
-
@customer_id = customer_or_id.is_a?(Object::Customer) ? customer_or_id.id : customer_or_id
|
21
|
-
self
|
22
|
-
end
|
23
|
-
end
|
24
|
-
end
|
25
|
-
end
|
26
|
-
end
|
27
|
-
end
|
@@ -1,27 +0,0 @@
|
|
1
|
-
require 'open-uri'
|
2
|
-
|
3
|
-
module Mollie
|
4
|
-
module API
|
5
|
-
module Resource
|
6
|
-
class Payments
|
7
|
-
class Refunds < Base
|
8
|
-
@payment_id = nil
|
9
|
-
|
10
|
-
def resource_object
|
11
|
-
Object::Payment::Refund
|
12
|
-
end
|
13
|
-
|
14
|
-
def resource_name
|
15
|
-
payment_id = URI::encode(@payment_id)
|
16
|
-
"payments/#{payment_id}/refunds"
|
17
|
-
end
|
18
|
-
|
19
|
-
def with(payment_or_id)
|
20
|
-
@payment_id = payment_or_id.is_a?(Object::Payment) ? payment_or_id.id : payment_or_id
|
21
|
-
self
|
22
|
-
end
|
23
|
-
end
|
24
|
-
end
|
25
|
-
end
|
26
|
-
end
|
27
|
-
end
|
@@ -1,31 +0,0 @@
|
|
1
|
-
module Mollie
|
2
|
-
module API
|
3
|
-
module Resource
|
4
|
-
class Permissions < Base
|
5
|
-
def self.available
|
6
|
-
%w(
|
7
|
-
payments.read
|
8
|
-
payments.write
|
9
|
-
refunds.read
|
10
|
-
refunds.write
|
11
|
-
customers.read
|
12
|
-
customers.write
|
13
|
-
mandates.read
|
14
|
-
mandates.write
|
15
|
-
subscriptions.read
|
16
|
-
subscriptions.write
|
17
|
-
profiles.read
|
18
|
-
profiles.write
|
19
|
-
invoices.read
|
20
|
-
settlements.read
|
21
|
-
organizations.read
|
22
|
-
organizations.write)
|
23
|
-
end
|
24
|
-
|
25
|
-
def resource_object
|
26
|
-
Object::Permission
|
27
|
-
end
|
28
|
-
end
|
29
|
-
end
|
30
|
-
end
|
31
|
-
end
|