-
Notifications
You must be signed in to change notification settings - Fork 533
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Update generated code for v275 * Update generated code for v276 --------- Co-authored-by: Stripe OpenAPI <105521251+stripe-openapi[bot]@users.noreply.github.com>
- Loading branch information
1 parent
980b7b0
commit 57f61c0
Showing
5 changed files
with
85 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
v232 | ||
v276 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
# File generated from our OpenAPI spec | ||
# frozen_string_literal: true | ||
|
||
module Stripe | ||
module Tax | ||
# A Tax `Calculation` allows you to calculate the tax to collect from your customer. | ||
class Calculation < APIResource | ||
extend Stripe::APIOperations::Create | ||
|
||
OBJECT_NAME = "tax.calculation" | ||
|
||
def list_line_items(params = {}, opts = {}) | ||
request_stripe_object( | ||
method: :get, | ||
path: format("/v1/tax/calculations/%<calculation>s/line_items", { calculation: CGI.escape(self["id"]) }), | ||
params: params, | ||
opts: opts | ||
) | ||
end | ||
|
||
def self.list_line_items(calculation, params = {}, opts = {}) | ||
request_stripe_object( | ||
method: :get, | ||
path: format("/v1/tax/calculations/%<calculation>s/line_items", { calculation: CGI.escape(calculation) }), | ||
params: params, | ||
opts: opts | ||
) | ||
end | ||
end | ||
end | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
# File generated from our OpenAPI spec | ||
# frozen_string_literal: true | ||
|
||
module Stripe | ||
module Tax | ||
# A Tax transaction records the tax collected from or refunded to your customer. | ||
class Transaction < APIResource | ||
extend Stripe::APIOperations::Create | ||
|
||
OBJECT_NAME = "tax.transaction" | ||
|
||
def list_line_items(params = {}, opts = {}) | ||
request_stripe_object( | ||
method: :get, | ||
path: format("/v1/tax/transactions/%<transaction>s/line_items", { transaction: CGI.escape(self["id"]) }), | ||
params: params, | ||
opts: opts | ||
) | ||
end | ||
|
||
def self.create_from_calculation(params = {}, opts = {}) | ||
request_stripe_object( | ||
method: :post, | ||
path: "/v1/tax/transactions/create_from_calculation", | ||
params: params, | ||
opts: opts | ||
) | ||
end | ||
|
||
def self.create_reversal(params = {}, opts = {}) | ||
request_stripe_object( | ||
method: :post, | ||
path: "/v1/tax/transactions/create_reversal", | ||
params: params, | ||
opts: opts | ||
) | ||
end | ||
|
||
def self.list_line_items(transaction, params = {}, opts = {}) | ||
request_stripe_object( | ||
method: :get, | ||
path: format("/v1/tax/transactions/%<transaction>s/line_items", { transaction: CGI.escape(transaction) }), | ||
params: params, | ||
opts: opts | ||
) | ||
end | ||
end | ||
end | ||
end |