Class: Stripe::Issuing::Authorization::TestHelpers
- Inherits:
-
APIResourceTestHelpers
- Object
- APIResourceTestHelpers
- Stripe::Issuing::Authorization::TestHelpers
- Defined in:
- lib/stripe/resources/issuing/authorization.rb
Constant Summary collapse
- RESOURCE_CLASS =
Authorization
Class Method Summary collapse
-
.capture(authorization, params = {}, opts = {}) ⇒ Object
Capture a test-mode authorization.
-
.create(params = {}, opts = {}) ⇒ Object
Create a test-mode authorization.
-
.expire(authorization, params = {}, opts = {}) ⇒ Object
Expire a test-mode Authorization.
-
.increment(authorization, params = {}, opts = {}) ⇒ Object
Increment a test-mode Authorization.
-
.reverse(authorization, params = {}, opts = {}) ⇒ Object
Reverse a test-mode Authorization.
Instance Method Summary collapse
-
#capture(params = {}, opts = {}) ⇒ Object
Capture a test-mode authorization.
-
#expire(params = {}, opts = {}) ⇒ Object
Expire a test-mode Authorization.
-
#increment(params = {}, opts = {}) ⇒ Object
Increment a test-mode Authorization.
-
#reverse(params = {}, opts = {}) ⇒ Object
Reverse a test-mode Authorization.
Methods inherited from APIResourceTestHelpers
custom_method, #initialize, resource_url, #resource_url
Methods included from APIOperations::Request
Constructor Details
This class inherits a constructor from Stripe::APIResourceTestHelpers
Class Method Details
.capture(authorization, params = {}, opts = {}) ⇒ Object
Capture a test-mode authorization.
69 70 71 72 73 74 75 76 |
# File 'lib/stripe/resources/issuing/authorization.rb', line 69 def self.capture(, params = {}, opts = {}) request_stripe_object( method: :post, path: format("/v1/test_helpers/issuing/authorizations/%<authorization>s/capture", { authorization: CGI.escape() }), params: params, opts: opts ) end |
.create(params = {}, opts = {}) ⇒ Object
Create a test-mode authorization.
79 80 81 82 83 84 85 86 |
# File 'lib/stripe/resources/issuing/authorization.rb', line 79 def self.create(params = {}, opts = {}) request_stripe_object( method: :post, path: "/v1/test_helpers/issuing/authorizations", params: params, opts: opts ) end |
.expire(authorization, params = {}, opts = {}) ⇒ Object
Expire a test-mode Authorization.
89 90 91 92 93 94 95 96 |
# File 'lib/stripe/resources/issuing/authorization.rb', line 89 def self.expire(, params = {}, opts = {}) request_stripe_object( method: :post, path: format("/v1/test_helpers/issuing/authorizations/%<authorization>s/expire", { authorization: CGI.escape() }), params: params, opts: opts ) end |
.increment(authorization, params = {}, opts = {}) ⇒ Object
Increment a test-mode Authorization.
99 100 101 102 103 104 105 106 |
# File 'lib/stripe/resources/issuing/authorization.rb', line 99 def self.increment(, params = {}, opts = {}) request_stripe_object( method: :post, path: format("/v1/test_helpers/issuing/authorizations/%<authorization>s/increment", { authorization: CGI.escape() }), params: params, opts: opts ) end |
.reverse(authorization, params = {}, opts = {}) ⇒ Object
Reverse a test-mode Authorization.
109 110 111 112 113 114 115 116 |
# File 'lib/stripe/resources/issuing/authorization.rb', line 109 def self.reverse(, params = {}, opts = {}) request_stripe_object( method: :post, path: format("/v1/test_helpers/issuing/authorizations/%<authorization>s/reverse", { authorization: CGI.escape() }), params: params, opts: opts ) end |
Instance Method Details
#capture(params = {}, opts = {}) ⇒ Object
Capture a test-mode authorization.
119 120 121 122 123 124 125 126 |
# File 'lib/stripe/resources/issuing/authorization.rb', line 119 def capture(params = {}, opts = {}) @resource.request_stripe_object( method: :post, path: format("/v1/test_helpers/issuing/authorizations/%<authorization>s/capture", { authorization: CGI.escape(@resource["id"]) }), params: params, opts: opts ) end |
#expire(params = {}, opts = {}) ⇒ Object
Expire a test-mode Authorization.
129 130 131 132 133 134 135 136 |
# File 'lib/stripe/resources/issuing/authorization.rb', line 129 def expire(params = {}, opts = {}) @resource.request_stripe_object( method: :post, path: format("/v1/test_helpers/issuing/authorizations/%<authorization>s/expire", { authorization: CGI.escape(@resource["id"]) }), params: params, opts: opts ) end |
#increment(params = {}, opts = {}) ⇒ Object
Increment a test-mode Authorization.
139 140 141 142 143 144 145 146 |
# File 'lib/stripe/resources/issuing/authorization.rb', line 139 def increment(params = {}, opts = {}) @resource.request_stripe_object( method: :post, path: format("/v1/test_helpers/issuing/authorizations/%<authorization>s/increment", { authorization: CGI.escape(@resource["id"]) }), params: params, opts: opts ) end |
#reverse(params = {}, opts = {}) ⇒ Object
Reverse a test-mode Authorization.
149 150 151 152 153 154 155 156 |
# File 'lib/stripe/resources/issuing/authorization.rb', line 149 def reverse(params = {}, opts = {}) @resource.request_stripe_object( method: :post, path: format("/v1/test_helpers/issuing/authorizations/%<authorization>s/reverse", { authorization: CGI.escape(@resource["id"]) }), params: params, opts: opts ) end |