From b5d30383dc3af990034904caf966da33ea3ddb9a Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Fri, 19 Dec 2025 00:13:15 +0000 Subject: [PATCH 1/2] feat(api): api update --- .stats.yml | 4 +- .../simulations/export_create_params.rb | 49 +++++++-- lib/increase/resources/simulations/exports.rb | 14 ++- .../simulations/export_create_params.rbi | 100 ++++++++++++++++-- .../resources/simulations/exports.rbi | 17 ++- .../simulations/export_create_params.rbs | 41 ++++++- .../resources/simulations/exports.rbs | 3 +- .../resources/simulations/exports_test.rb | 2 +- 8 files changed, 202 insertions(+), 28 deletions(-) diff --git a/.stats.yml b/.stats.yml index 4bf821de..b1d32ecc 100644 --- a/.stats.yml +++ b/.stats.yml @@ -1,4 +1,4 @@ configured_endpoints: 227 -openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/increase%2Fincrease-60f9bca532c8805735c227730bbb14858faa64bfd5f83a1a78640f0119a3f99c.yml -openapi_spec_hash: 17ddd87efe6c029f2fa660c8781ccfaf +openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/increase%2Fincrease-63db8a5872b6a112abfc879f75a53bc6975994025752e86b27ab327884d94655.yml +openapi_spec_hash: b7ffb71e0102fcd040a575bf917656e3 config_hash: ca52ca9a2968f330339fd50c1a386e05 diff --git a/lib/increase/models/simulations/export_create_params.rb b/lib/increase/models/simulations/export_create_params.rb index c00a4548..bdbcee4d 100644 --- a/lib/increase/models/simulations/export_create_params.rb +++ b/lib/increase/models/simulations/export_create_params.rb @@ -8,16 +8,53 @@ class ExportCreateParams < Increase::Internal::Type::BaseModel extend Increase::Internal::Type::RequestParameters::Converter include Increase::Internal::Type::RequestParameters - # @!attribute account_id - # The identifier of the Account the tax document is for. + # @!attribute category + # The type of Export to create. # - # @return [String] - required :account_id, String + # @return [Symbol, Increase::Models::Simulations::ExportCreateParams::Category] + required :category, enum: -> { Increase::Simulations::ExportCreateParams::Category } - # @!method initialize(account_id:, request_options: {}) - # @param account_id [String] The identifier of the Account the tax document is for. + # @!attribute form_1099_int + # Options for the created export. Required if `category` is equal to + # `form_1099_int`. + # + # @return [Increase::Models::Simulations::ExportCreateParams::Form1099Int, nil] + optional :form_1099_int, -> { Increase::Simulations::ExportCreateParams::Form1099Int } + + # @!method initialize(category:, form_1099_int: nil, request_options: {}) + # Some parameter documentations has been truncated, see + # {Increase::Models::Simulations::ExportCreateParams} for more details. + # + # @param category [Symbol, Increase::Models::Simulations::ExportCreateParams::Category] The type of Export to create. + # + # @param form_1099_int [Increase::Models::Simulations::ExportCreateParams::Form1099Int] Options for the created export. Required if `category` is equal to `form_1099_in # # @param request_options [Increase::RequestOptions, Hash{Symbol=>Object}] + + # The type of Export to create. + module Category + extend Increase::Internal::Type::Enum + + # A PDF of an Internal Revenue Service Form 1099-INT. + FORM_1099_INT = :form_1099_int + + # @!method self.values + # @return [Array] + end + + class Form1099Int < Increase::Internal::Type::BaseModel + # @!attribute account_id + # The identifier of the Account the tax document is for. + # + # @return [String] + required :account_id, String + + # @!method initialize(account_id:) + # Options for the created export. Required if `category` is equal to + # `form_1099_int`. + # + # @param account_id [String] The identifier of the Account the tax document is for. + end end end end diff --git a/lib/increase/resources/simulations/exports.rb b/lib/increase/resources/simulations/exports.rb index d4a4bd27..e91f0d26 100644 --- a/lib/increase/resources/simulations/exports.rb +++ b/lib/increase/resources/simulations/exports.rb @@ -4,11 +4,19 @@ module Increase module Resources class Simulations class Exports - # Simulates a tax form export being generated. + # Some parameter documentations has been truncated, see + # {Increase::Models::Simulations::ExportCreateParams} for more details. # - # @overload create(account_id:, request_options: {}) + # Many exports are created by you via POST /exports or in the Dashboard. Some + # exports are created automatically by Increase. For example, tax documents are + # published once a year. In sandbox, you can trigger the arrival of an export that + # would normally only be created automatically via this simulation. # - # @param account_id [String] The identifier of the Account the tax document is for. + # @overload create(category:, form_1099_int: nil, request_options: {}) + # + # @param category [Symbol, Increase::Models::Simulations::ExportCreateParams::Category] The type of Export to create. + # + # @param form_1099_int [Increase::Models::Simulations::ExportCreateParams::Form1099Int] Options for the created export. Required if `category` is equal to `form_1099_in # # @param request_options [Increase::RequestOptions, Hash{Symbol=>Object}, nil] # diff --git a/rbi/increase/models/simulations/export_create_params.rbi b/rbi/increase/models/simulations/export_create_params.rbi index d6a9ca44..f0e5cb54 100644 --- a/rbi/increase/models/simulations/export_create_params.rbi +++ b/rbi/increase/models/simulations/export_create_params.rbi @@ -15,30 +15,116 @@ module Increase ) end - # The identifier of the Account the tax document is for. - sig { returns(String) } - attr_accessor :account_id + # The type of Export to create. + sig do + returns(Increase::Simulations::ExportCreateParams::Category::OrSymbol) + end + attr_accessor :category + + # Options for the created export. Required if `category` is equal to + # `form_1099_int`. + sig do + returns( + T.nilable(Increase::Simulations::ExportCreateParams::Form1099Int) + ) + end + attr_reader :form_1099_int sig do params( - account_id: String, + form_1099_int: + Increase::Simulations::ExportCreateParams::Form1099Int::OrHash + ).void + end + attr_writer :form_1099_int + + sig do + params( + category: + Increase::Simulations::ExportCreateParams::Category::OrSymbol, + form_1099_int: + Increase::Simulations::ExportCreateParams::Form1099Int::OrHash, request_options: Increase::RequestOptions::OrHash ).returns(T.attached_class) end def self.new( - # The identifier of the Account the tax document is for. - account_id:, + # The type of Export to create. + category:, + # Options for the created export. Required if `category` is equal to + # `form_1099_int`. + form_1099_int: nil, request_options: {} ) end sig do override.returns( - { account_id: String, request_options: Increase::RequestOptions } + { + category: + Increase::Simulations::ExportCreateParams::Category::OrSymbol, + form_1099_int: + Increase::Simulations::ExportCreateParams::Form1099Int, + request_options: Increase::RequestOptions + } ) end def to_hash end + + # The type of Export to create. + module Category + extend Increase::Internal::Type::Enum + + TaggedSymbol = + T.type_alias do + T.all(Symbol, Increase::Simulations::ExportCreateParams::Category) + end + OrSymbol = T.type_alias { T.any(Symbol, String) } + + # A PDF of an Internal Revenue Service Form 1099-INT. + FORM_1099_INT = + T.let( + :form_1099_int, + Increase::Simulations::ExportCreateParams::Category::TaggedSymbol + ) + + sig do + override.returns( + T::Array[ + Increase::Simulations::ExportCreateParams::Category::TaggedSymbol + ] + ) + end + def self.values + end + end + + class Form1099Int < Increase::Internal::Type::BaseModel + OrHash = + T.type_alias do + T.any( + Increase::Simulations::ExportCreateParams::Form1099Int, + Increase::Internal::AnyHash + ) + end + + # The identifier of the Account the tax document is for. + sig { returns(String) } + attr_accessor :account_id + + # Options for the created export. Required if `category` is equal to + # `form_1099_int`. + sig { params(account_id: String).returns(T.attached_class) } + def self.new( + # The identifier of the Account the tax document is for. + account_id: + ) + end + + sig { override.returns({ account_id: String }) } + def to_hash + end + end end end end diff --git a/rbi/increase/resources/simulations/exports.rbi b/rbi/increase/resources/simulations/exports.rbi index 2ef5ca9d..1eca934b 100644 --- a/rbi/increase/resources/simulations/exports.rbi +++ b/rbi/increase/resources/simulations/exports.rbi @@ -4,16 +4,25 @@ module Increase module Resources class Simulations class Exports - # Simulates a tax form export being generated. + # Many exports are created by you via POST /exports or in the Dashboard. Some + # exports are created automatically by Increase. For example, tax documents are + # published once a year. In sandbox, you can trigger the arrival of an export that + # would normally only be created automatically via this simulation. sig do params( - account_id: String, + category: + Increase::Simulations::ExportCreateParams::Category::OrSymbol, + form_1099_int: + Increase::Simulations::ExportCreateParams::Form1099Int::OrHash, request_options: Increase::RequestOptions::OrHash ).returns(Increase::Export) end def create( - # The identifier of the Account the tax document is for. - account_id:, + # The type of Export to create. + category:, + # Options for the created export. Required if `category` is equal to + # `form_1099_int`. + form_1099_int: nil, request_options: {} ) end diff --git a/sig/increase/models/simulations/export_create_params.rbs b/sig/increase/models/simulations/export_create_params.rbs index cda284d0..7b062350 100644 --- a/sig/increase/models/simulations/export_create_params.rbs +++ b/sig/increase/models/simulations/export_create_params.rbs @@ -2,23 +2,56 @@ module Increase module Models module Simulations type export_create_params = - { account_id: String } & Increase::Internal::Type::request_parameters + { + category: Increase::Models::Simulations::ExportCreateParams::category, + :form_1099_int => Increase::Simulations::ExportCreateParams::Form1099Int + } + & Increase::Internal::Type::request_parameters class ExportCreateParams < Increase::Internal::Type::BaseModel extend Increase::Internal::Type::RequestParameters::Converter include Increase::Internal::Type::RequestParameters - attr_accessor account_id: String + attr_accessor category: Increase::Models::Simulations::ExportCreateParams::category + + attr_reader form_1099_int: Increase::Simulations::ExportCreateParams::Form1099Int? + + def form_1099_int=: ( + Increase::Simulations::ExportCreateParams::Form1099Int + ) -> Increase::Simulations::ExportCreateParams::Form1099Int def initialize: ( - account_id: String, + category: Increase::Models::Simulations::ExportCreateParams::category, + ?form_1099_int: Increase::Simulations::ExportCreateParams::Form1099Int, ?request_options: Increase::request_opts ) -> void def to_hash: -> { - account_id: String, + category: Increase::Models::Simulations::ExportCreateParams::category, + :form_1099_int => Increase::Simulations::ExportCreateParams::Form1099Int, request_options: Increase::RequestOptions } + + type category = :form_1099_int + + module Category + extend Increase::Internal::Type::Enum + + # A PDF of an Internal Revenue Service Form 1099-INT. + FORM_1099_INT: :form_1099_int + + def self?.values: -> ::Array[Increase::Models::Simulations::ExportCreateParams::category] + end + + type form1099_int = { account_id: String } + + class Form1099Int < Increase::Internal::Type::BaseModel + attr_accessor account_id: String + + def initialize: (account_id: String) -> void + + def to_hash: -> { account_id: String } + end end end end diff --git a/sig/increase/resources/simulations/exports.rbs b/sig/increase/resources/simulations/exports.rbs index 47ac4023..218f9830 100644 --- a/sig/increase/resources/simulations/exports.rbs +++ b/sig/increase/resources/simulations/exports.rbs @@ -3,7 +3,8 @@ module Increase class Simulations class Exports def create: ( - account_id: String, + category: Increase::Models::Simulations::ExportCreateParams::category, + ?form_1099_int: Increase::Simulations::ExportCreateParams::Form1099Int, ?request_options: Increase::request_opts ) -> Increase::Export diff --git a/test/increase/resources/simulations/exports_test.rb b/test/increase/resources/simulations/exports_test.rb index fce3070c..c9a60ccf 100644 --- a/test/increase/resources/simulations/exports_test.rb +++ b/test/increase/resources/simulations/exports_test.rb @@ -4,7 +4,7 @@ class Increase::Test::Resources::Simulations::ExportsTest < Increase::Test::ResourceTest def test_create_required_params - response = @increase.simulations.exports.create(account_id: "account_in71c4amph0vgo2qllky") + response = @increase.simulations.exports.create(category: :form_1099_int) assert_pattern do response => Increase::Export From 51417501f6dfd948d2ee2d7d7305a9dc4d332a49 Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Fri, 19 Dec 2025 00:13:36 +0000 Subject: [PATCH 2/2] release: 1.169.0 --- .release-please-manifest.json | 2 +- CHANGELOG.md | 8 ++++++++ Gemfile.lock | 2 +- README.md | 2 +- lib/increase/version.rb | 2 +- 5 files changed, 12 insertions(+), 4 deletions(-) diff --git a/.release-please-manifest.json b/.release-please-manifest.json index 64314dc2..91922acb 100644 --- a/.release-please-manifest.json +++ b/.release-please-manifest.json @@ -1,3 +1,3 @@ { - ".": "1.168.0" + ".": "1.169.0" } \ No newline at end of file diff --git a/CHANGELOG.md b/CHANGELOG.md index 901dc383..bc3344b2 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,13 @@ # Changelog +## 1.169.0 (2025-12-19) + +Full Changelog: [v1.168.0...v1.169.0](https://github.com/Increase/increase-ruby/compare/v1.168.0...v1.169.0) + +### Features + +* **api:** api update ([b5d3038](https://github.com/Increase/increase-ruby/commit/b5d30383dc3af990034904caf966da33ea3ddb9a)) + ## 1.168.0 (2025-12-18) Full Changelog: [v1.167.0...v1.168.0](https://github.com/Increase/increase-ruby/compare/v1.167.0...v1.168.0) diff --git a/Gemfile.lock b/Gemfile.lock index f045ad0f..7b22d151 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -11,7 +11,7 @@ GIT PATH remote: . specs: - increase (1.168.0) + increase (1.169.0) connection_pool GEM diff --git a/README.md b/README.md index a6ed81a0..6853d26c 100644 --- a/README.md +++ b/README.md @@ -15,7 +15,7 @@ To use this gem, install via Bundler by adding the following to your application ```ruby -gem "increase", "~> 1.168.0" +gem "increase", "~> 1.169.0" ``` diff --git a/lib/increase/version.rb b/lib/increase/version.rb index 1b80fc23..a284b92a 100644 --- a/lib/increase/version.rb +++ b/lib/increase/version.rb @@ -1,5 +1,5 @@ # frozen_string_literal: true module Increase - VERSION = "1.168.0" + VERSION = "1.169.0" end