Skip to content

Commit 4ada9ae

Browse files
feat(api): api update
1 parent e127e2e commit 4ada9ae

9 files changed

Lines changed: 66 additions & 46 deletions

File tree

.stats.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
configured_endpoints: 46
2-
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/finch%2Ffinch-970ab04a97244c68824c0c52e06925cba14fb7dbfc36c03167c1afe74cd1b150.yml
3-
openapi_spec_hash: 315e7859c3f77311261fb824b74a8247
4-
config_hash: f2846563903bf75ab0858872154df0f7
2+
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/finch%2Ffinch-d9cb320c8313cd122b4851d726c6cea39a14a5317880c6d063671ad3f412e632.yml
3+
openapi_spec_hash: 58c2cf578f0736b8c5df957f6a61190b
4+
config_hash: 0892e2e0eeb0343a022afa62e9080dd1

lib/finch_api/models/request_forwarding_forward_params.rb

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -29,26 +29,26 @@ class RequestForwardingForwardParams < FinchAPI::Internal::Type::BaseModel
2929
# @return [String, nil]
3030
optional :data, String, nil?: true
3131

32-
# @!attribute headers
33-
# The HTTP headers to include on the forwarded request. This value must be
34-
# specified as an object of key-value pairs. Example:
35-
# `{"Content-Type": "application/xml", "X-API-Version": "v1" }`
32+
# @!attribute params
33+
# The query parameters for the forwarded request. This value must be specified as
34+
# a valid JSON object rather than a query string.
3635
#
3736
# @return [Hash{Symbol=>Object, nil}, nil]
38-
optional :headers,
37+
optional :params,
3938
FinchAPI::Internal::Type::HashOf[FinchAPI::Internal::Type::Unknown, nil?: true],
4039
nil?: true
4140

42-
# @!attribute params
43-
# The query parameters for the forwarded request. This value must be specified as
44-
# a valid JSON object rather than a query string.
41+
# @!attribute request_headers
42+
# The HTTP headers to include on the forwarded request. This value must be
43+
# specified as an object of key-value pairs. Example:
44+
# `{"Content-Type": "application/xml", "X-API-Version": "v1" }`
4545
#
4646
# @return [Hash{Symbol=>Object, nil}, nil]
47-
optional :params,
47+
optional :request_headers,
4848
FinchAPI::Internal::Type::HashOf[FinchAPI::Internal::Type::Unknown, nil?: true],
4949
nil?: true
5050

51-
# @!method initialize(method_:, route:, data: nil, headers: nil, params: nil, request_options: {})
51+
# @!method initialize(method_:, route:, data: nil, params: nil, request_headers: nil, request_options: {})
5252
# Some parameter documentations has been truncated, see
5353
# {FinchAPI::Models::RequestForwardingForwardParams} for more details.
5454
#
@@ -58,10 +58,10 @@ class RequestForwardingForwardParams < FinchAPI::Internal::Type::BaseModel
5858
#
5959
# @param data [String, nil] The body for the forwarded request. This value must be specified as either a str
6060
#
61-
# @param headers [Hash{Symbol=>Object, nil}, nil] The HTTP headers to include on the forwarded request. This value must be specifi
62-
#
6361
# @param params [Hash{Symbol=>Object, nil}, nil] The query parameters for the forwarded request. This value must be specified as
6462
#
63+
# @param request_headers [Hash{Symbol=>Object, nil}, nil] The HTTP headers to include on the forwarded request. This value must be specifi
64+
#
6565
# @param request_options [FinchAPI::RequestOptions, Hash{Symbol=>Object}]
6666
end
6767
end

lib/finch_api/models/sandbox/payment_create_params.rb

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -160,6 +160,7 @@ class EmployeeDeduction < FinchAPI::Internal::Type::BaseModel
160160
optional :amount, Integer
161161

162162
# @!attribute name
163+
# The deduction name. Required when type is specified.
163164
#
164165
# @return [String, nil]
165166
optional :name, String
@@ -176,8 +177,11 @@ class EmployeeDeduction < FinchAPI::Internal::Type::BaseModel
176177

177178
# @!method initialize(amount: nil, name: nil, pre_tax: nil, type: nil)
178179
# @param amount [Integer]
179-
# @param name [String]
180+
#
181+
# @param name [String] The deduction name. Required when type is specified.
182+
#
180183
# @param pre_tax [Boolean]
184+
#
181185
# @param type [Symbol, FinchAPI::Models::Sandbox::PaymentCreateParams::PayStatement::EmployeeDeduction::Type]
182186

183187
# @see FinchAPI::Models::Sandbox::PaymentCreateParams::PayStatement::EmployeeDeduction#type
@@ -216,6 +220,7 @@ class EmployerContribution < FinchAPI::Internal::Type::BaseModel
216220
optional :amount, Integer
217221

218222
# @!attribute name
223+
# The contribution name. Required when type is specified.
219224
#
220225
# @return [String, nil]
221226
optional :name, String
@@ -228,7 +233,9 @@ class EmployerContribution < FinchAPI::Internal::Type::BaseModel
228233

229234
# @!method initialize(amount: nil, name: nil, type: nil)
230235
# @param amount [Integer]
231-
# @param name [String]
236+
#
237+
# @param name [String] The contribution name. Required when type is specified.
238+
#
232239
# @param type [Symbol, FinchAPI::Models::Sandbox::PaymentCreateParams::PayStatement::EmployerContribution::Type]
233240

234241
# @see FinchAPI::Models::Sandbox::PaymentCreateParams::PayStatement::EmployerContribution#type

lib/finch_api/resources/request_forwarding.rb

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,18 +11,18 @@ class RequestForwarding
1111
# Forward allows you to push or pull data models directly against an integration's
1212
# API.
1313
#
14-
# @overload forward(method_:, route:, data: nil, headers: nil, params: nil, request_options: {})
14+
# @overload forward(method_:, route:, data: nil, params: nil, request_headers: nil, request_options: {})
1515
#
1616
# @param method_ [String] The HTTP method for the forwarded request. Valid values include: `GET` , `POST`
1717
#
1818
# @param route [String] The URL route path for the forwarded request. This value must begin with a forwa
1919
#
2020
# @param data [String, nil] The body for the forwarded request. This value must be specified as either a str
2121
#
22-
# @param headers [Hash{Symbol=>Object, nil}, nil] The HTTP headers to include on the forwarded request. This value must be specifi
23-
#
2422
# @param params [Hash{Symbol=>Object, nil}, nil] The query parameters for the forwarded request. This value must be specified as
2523
#
24+
# @param request_headers [Hash{Symbol=>Object, nil}, nil] The HTTP headers to include on the forwarded request. This value must be specifi
25+
#
2626
# @param request_options [FinchAPI::RequestOptions, Hash{Symbol=>Object}, nil]
2727
#
2828
# @return [FinchAPI::Models::RequestForwardingForwardResponse]

rbi/finch_api/models/request_forwarding_forward_params.rbi

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -30,24 +30,24 @@ module FinchAPI
3030
sig { returns(T.nilable(String)) }
3131
attr_accessor :data
3232

33-
# The HTTP headers to include on the forwarded request. This value must be
34-
# specified as an object of key-value pairs. Example:
35-
# `{"Content-Type": "application/xml", "X-API-Version": "v1" }`
36-
sig { returns(T.nilable(T::Hash[Symbol, T.nilable(T.anything)])) }
37-
attr_accessor :headers
38-
3933
# The query parameters for the forwarded request. This value must be specified as
4034
# a valid JSON object rather than a query string.
4135
sig { returns(T.nilable(T::Hash[Symbol, T.nilable(T.anything)])) }
4236
attr_accessor :params
4337

38+
# The HTTP headers to include on the forwarded request. This value must be
39+
# specified as an object of key-value pairs. Example:
40+
# `{"Content-Type": "application/xml", "X-API-Version": "v1" }`
41+
sig { returns(T.nilable(T::Hash[Symbol, T.nilable(T.anything)])) }
42+
attr_accessor :request_headers
43+
4444
sig do
4545
params(
4646
method_: String,
4747
route: String,
4848
data: T.nilable(String),
49-
headers: T.nilable(T::Hash[Symbol, T.nilable(T.anything)]),
5049
params: T.nilable(T::Hash[Symbol, T.nilable(T.anything)]),
50+
request_headers: T.nilable(T::Hash[Symbol, T.nilable(T.anything)]),
5151
request_options: FinchAPI::RequestOptions::OrHash
5252
).returns(T.attached_class)
5353
end
@@ -62,13 +62,13 @@ module FinchAPI
6262
# The body for the forwarded request. This value must be specified as either a
6363
# string or a valid JSON object.
6464
data: nil,
65-
# The HTTP headers to include on the forwarded request. This value must be
66-
# specified as an object of key-value pairs. Example:
67-
# `{"Content-Type": "application/xml", "X-API-Version": "v1" }`
68-
headers: nil,
6965
# The query parameters for the forwarded request. This value must be specified as
7066
# a valid JSON object rather than a query string.
7167
params: nil,
68+
# The HTTP headers to include on the forwarded request. This value must be
69+
# specified as an object of key-value pairs. Example:
70+
# `{"Content-Type": "application/xml", "X-API-Version": "v1" }`
71+
request_headers: nil,
7272
request_options: {}
7373
)
7474
end
@@ -79,8 +79,8 @@ module FinchAPI
7979
method_: String,
8080
route: String,
8181
data: T.nilable(String),
82-
headers: T.nilable(T::Hash[Symbol, T.nilable(T.anything)]),
8382
params: T.nilable(T::Hash[Symbol, T.nilable(T.anything)]),
83+
request_headers: T.nilable(T::Hash[Symbol, T.nilable(T.anything)]),
8484
request_options: FinchAPI::RequestOptions
8585
}
8686
)

rbi/finch_api/models/sandbox/payment_create_params.rbi

Lines changed: 15 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -471,6 +471,7 @@ module FinchAPI
471471
sig { params(amount: Integer).void }
472472
attr_writer :amount
473473

474+
# The deduction name. Required when type is specified.
474475
sig { returns(T.nilable(String)) }
475476
attr_reader :name
476477

@@ -509,7 +510,13 @@ module FinchAPI
509510
FinchAPI::Sandbox::PaymentCreateParams::PayStatement::EmployeeDeduction::Type::OrSymbol
510511
).returns(T.attached_class)
511512
end
512-
def self.new(amount: nil, name: nil, pre_tax: nil, type: nil)
513+
def self.new(
514+
amount: nil,
515+
# The deduction name. Required when type is specified.
516+
name: nil,
517+
pre_tax: nil,
518+
type: nil
519+
)
513520
end
514521

515522
sig do
@@ -661,6 +668,7 @@ module FinchAPI
661668
sig { params(amount: Integer).void }
662669
attr_writer :amount
663670

671+
# The contribution name. Required when type is specified.
664672
sig { returns(T.nilable(String)) }
665673
attr_reader :name
666674

@@ -692,7 +700,12 @@ module FinchAPI
692700
FinchAPI::Sandbox::PaymentCreateParams::PayStatement::EmployerContribution::Type::OrSymbol
693701
).returns(T.attached_class)
694702
end
695-
def self.new(amount: nil, name: nil, type: nil)
703+
def self.new(
704+
amount: nil,
705+
# The contribution name. Required when type is specified.
706+
name: nil,
707+
type: nil
708+
)
696709
end
697710

698711
sig do

rbi/finch_api/resources/request_forwarding.rbi

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,8 @@ module FinchAPI
1212
method_: String,
1313
route: String,
1414
data: T.nilable(String),
15-
headers: T.nilable(T::Hash[Symbol, T.nilable(T.anything)]),
1615
params: T.nilable(T::Hash[Symbol, T.nilable(T.anything)]),
16+
request_headers: T.nilable(T::Hash[Symbol, T.nilable(T.anything)]),
1717
request_options: FinchAPI::RequestOptions::OrHash
1818
).returns(FinchAPI::Models::RequestForwardingForwardResponse)
1919
end
@@ -28,13 +28,13 @@ module FinchAPI
2828
# The body for the forwarded request. This value must be specified as either a
2929
# string or a valid JSON object.
3030
data: nil,
31-
# The HTTP headers to include on the forwarded request. This value must be
32-
# specified as an object of key-value pairs. Example:
33-
# `{"Content-Type": "application/xml", "X-API-Version": "v1" }`
34-
headers: nil,
3531
# The query parameters for the forwarded request. This value must be specified as
3632
# a valid JSON object rather than a query string.
3733
params: nil,
34+
# The HTTP headers to include on the forwarded request. This value must be
35+
# specified as an object of key-value pairs. Example:
36+
# `{"Content-Type": "application/xml", "X-API-Version": "v1" }`
37+
request_headers: nil,
3838
request_options: {}
3939
)
4040
end

sig/finch_api/models/request_forwarding_forward_params.rbs

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,8 @@ module FinchAPI
55
method_: String,
66
route: String,
77
data: String?,
8-
headers: ::Hash[Symbol, top?]?,
9-
params: ::Hash[Symbol, top?]?
8+
params: ::Hash[Symbol, top?]?,
9+
request_headers: ::Hash[Symbol, top?]?
1010
}
1111
& FinchAPI::Internal::Type::request_parameters
1212

@@ -20,25 +20,25 @@ module FinchAPI
2020

2121
attr_accessor data: String?
2222

23-
attr_accessor headers: ::Hash[Symbol, top?]?
24-
2523
attr_accessor params: ::Hash[Symbol, top?]?
2624

25+
attr_accessor request_headers: ::Hash[Symbol, top?]?
26+
2727
def initialize: (
2828
method_: String,
2929
route: String,
3030
?data: String?,
31-
?headers: ::Hash[Symbol, top?]?,
3231
?params: ::Hash[Symbol, top?]?,
32+
?request_headers: ::Hash[Symbol, top?]?,
3333
?request_options: FinchAPI::request_opts
3434
) -> void
3535

3636
def to_hash: -> {
3737
method_: String,
3838
route: String,
3939
data: String?,
40-
headers: ::Hash[Symbol, top?]?,
4140
params: ::Hash[Symbol, top?]?,
41+
request_headers: ::Hash[Symbol, top?]?,
4242
request_options: FinchAPI::RequestOptions
4343
}
4444
end

sig/finch_api/resources/request_forwarding.rbs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,8 @@ module FinchAPI
55
method_: String,
66
route: String,
77
?data: String?,
8-
?headers: ::Hash[Symbol, top?]?,
98
?params: ::Hash[Symbol, top?]?,
9+
?request_headers: ::Hash[Symbol, top?]?,
1010
?request_options: FinchAPI::request_opts
1111
) -> FinchAPI::Models::RequestForwardingForwardResponse
1212

0 commit comments

Comments
 (0)