Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions .stats.yml
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
configured_endpoints: 254
openapi_spec_hash: 55fb271eb29805e8a49ed72fb5ed8843
config_hash: f0e1844d06c76a9e145f7986d993dda6
configured_endpoints: 255
openapi_spec_hash: ac38083f7c2804d34c4eaa265e21dbb5
config_hash: de151ebd21a0bd391662389b310a8f49
1 change: 1 addition & 0 deletions lib/increase.rb
Original file line number Diff line number Diff line change
Expand Up @@ -118,6 +118,7 @@
require_relative "increase/models/card_push_transfer_create_params"
require_relative "increase/models/card_push_transfer_list_params"
require_relative "increase/models/card_push_transfer_retrieve_params"
require_relative "increase/models/card_renew_params"
require_relative "increase/models/card_retrieve_params"
require_relative "increase/models/card_token"
require_relative "increase/models/card_token_capabilities"
Expand Down
2 changes: 2 additions & 0 deletions lib/increase/models.rb
Original file line number Diff line number Diff line change
Expand Up @@ -167,6 +167,8 @@ module Increase

CardPushTransferRetrieveParams = Increase::Models::CardPushTransferRetrieveParams

CardRenewParams = Increase::Models::CardRenewParams

CardRetrieveParams = Increase::Models::CardRetrieveParams

CardToken = Increase::Models::CardToken
Expand Down
20 changes: 12 additions & 8 deletions lib/increase/models/account_statement.rb
Original file line number Diff line number Diff line change
Expand Up @@ -50,17 +50,19 @@ class AccountStatement < Increase::Internal::Type::BaseModel
# @!attribute statement_period_end
# The [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) time representing the end
# of the period the Account Statement covers. The statement covers all
# transactions up to, but not including this timestamp. Usually, this is the
# beginning of the following month.
# transactions up to, but not including this timestamp. Statement periods are
# measured in UTC days, so this is usually midnight UTC on the first day of the
# following month.
#
# @return [Time]
required :statement_period_end, Time

# @!attribute statement_period_start
# The [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) time representing the
# start of the period the Account Statement covers. This is the first moment of
# the statement period and is inclusive. Usually, this is the beginning of the
# month this statement covers.
# the statement period and is inclusive. Statement periods are measured in UTC
# days, so this is usually midnight UTC on the first day of the month this
# statement covers.
#
# @return [Time]
required :statement_period_start, Time
Expand Down Expand Up @@ -96,14 +98,16 @@ class AccountStatement < Increase::Internal::Type::BaseModel
# @param statement_period_end [Time]
# The [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) time representing the end
# of the period the Account Statement covers. The statement covers all
# transactions up to, but not including this timestamp. Usually, this is the
# beginning of the following month.
# transactions up to, but not including this timestamp. Statement periods are
# measured in UTC days, so this is usually midnight UTC on the first day of the
# following month.
#
# @param statement_period_start [Time]
# The [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) time representing the
# start of the period the Account Statement covers. This is the first moment of
# the statement period and is inclusive. Usually, this is the beginning of the
# month this statement covers.
# the statement period and is inclusive. Statement periods are measured in UTC
# days, so this is usually midnight UTC on the first day of the month this
# statement covers.
#
# @param type [Symbol, Increase::Models::AccountStatement::Type]
# A constant representing the object's type. For this resource it will always be
Expand Down
47 changes: 46 additions & 1 deletion lib/increase/models/card.rb
Original file line number Diff line number Diff line change
Expand Up @@ -94,6 +94,13 @@ class Card < Increase::Internal::Type::BaseModel
# @return [String]
required :last4, String

# @!attribute renewals
# Completed renewals of this Card, sorted by `renewed_at` in ascending order. Each
# renewal records the expiration date the Card had before it was renewed.
#
# @return [Array<Increase::Models::Card::Renewal>]
required :renewals, -> { Increase::Internal::Type::ArrayOf[Increase::Card::Renewal] }

# @!attribute status
# This indicates if payments can be made with the card.
#
Expand All @@ -107,7 +114,7 @@ class Card < Increase::Internal::Type::BaseModel
# @return [Symbol, Increase::Models::Card::Type]
required :type, enum: -> { Increase::Card::Type }

# @!method initialize(id:, account_id:, authorization_controls:, billing_address:, bin:, cardholder_name:, created_at:, description:, digital_wallet:, entity_id:, expiration_month:, expiration_year:, idempotency_key:, last4:, status:, type:)
# @!method initialize(id:, account_id:, authorization_controls:, billing_address:, bin:, cardholder_name:, created_at:, description:, digital_wallet:, entity_id:, expiration_month:, expiration_year:, idempotency_key:, last4:, renewals:, status:, type:)
# Cards may operate on credit, debit, or prepaid BINs. They’ll immediately work
# for online purchases after you create them. All cards work on a good funds
# model, and maintain a maximum limit of 100% of the Account’s available balance
Expand Down Expand Up @@ -153,6 +160,10 @@ class Card < Increase::Internal::Type::BaseModel
#
# @param last4 [String] The last 4 digits of the Card's Primary Account Number.
#
# @param renewals [Array<Increase::Models::Card::Renewal>]
# Completed renewals of this Card, sorted by `renewed_at` in ascending order. Each
# renewal records the expiration date the Card had before it was renewed.
#
# @param status [Symbol, Increase::Models::Card::Status]
# This indicates if payments can be made with the card.
#
Expand Down Expand Up @@ -696,6 +707,40 @@ class DigitalWallet < Increase::Internal::Type::BaseModel
# over SMS.
end

class Renewal < Increase::Internal::Type::BaseModel
# @!attribute expiration_month
# The month the Card expired in before this renewal, in M format (e.g., August is
# 8).
#
# @return [Integer]
required :expiration_month, Integer

# @!attribute expiration_year
# The year the Card expired in before this renewal, in YYYY format (e.g., 2025).
#
# @return [Integer]
required :expiration_year, Integer

# @!attribute renewed_at
# The [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) date and time at which
# the Card was renewed.
#
# @return [Time]
required :renewed_at, Time

# @!method initialize(expiration_month:, expiration_year:, renewed_at:)
# @param expiration_month [Integer]
# The month the Card expired in before this renewal, in M format (e.g., August is
# 8).
#
# @param expiration_year [Integer]
# The year the Card expired in before this renewal, in YYYY format (e.g., 2025).
#
# @param renewed_at [Time]
# The [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) date and time at which
# the Card was renewed.
end

# This indicates if payments can be made with the card.
#
# @see Increase::Models::Card#status
Expand Down
22 changes: 22 additions & 0 deletions lib/increase/models/card_renew_params.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
# frozen_string_literal: true

module Increase
module Models
# @see Increase::Resources::Cards#renew
class CardRenewParams < Increase::Internal::Type::BaseModel
extend Increase::Internal::Type::RequestParameters::Converter
include Increase::Internal::Type::RequestParameters

# @!attribute card_id
# The identifier of the Card to renew.
#
# @return [String]
required :card_id, String

# @!method initialize(card_id:, request_options: {})
# @param card_id [String] The identifier of the Card to renew.
#
# @param request_options [Increase::RequestOptions, Hash{Symbol=>Object}]
end
end
end
24 changes: 12 additions & 12 deletions lib/increase/models/export.rb
Original file line number Diff line number Diff line change
Expand Up @@ -257,7 +257,7 @@ class AccountStatementBai2 < Increase::Internal::Type::BaseModel
required :account_id, String, nil?: true

# @!attribute effective_date
# The date for which to retrieve the balance.
# The UTC date for which to retrieve the balance.
#
# @return [Date, nil]
required :effective_date, Date, nil?: true
Expand All @@ -274,7 +274,7 @@ class AccountStatementBai2 < Increase::Internal::Type::BaseModel
#
# @param account_id [String, nil] Filter results by Account.
#
# @param effective_date [Date, nil] The date for which to retrieve the balance.
# @param effective_date [Date, nil] The UTC date for which to retrieve the balance.
#
# @param program_id [String, nil] Filter results by Program.
end
Expand Down Expand Up @@ -334,7 +334,7 @@ class AccountVerificationLetter < Increase::Internal::Type::BaseModel
required :account_number_id, String

# @!attribute balance_date
# The date of the balance to include in the letter.
# The UTC date of the balance to include in the letter.
#
# @return [Date, nil]
required :balance_date, Date, nil?: true
Expand All @@ -345,7 +345,7 @@ class AccountVerificationLetter < Increase::Internal::Type::BaseModel
#
# @param account_number_id [String] The Account Number to create a letter for.
#
# @param balance_date [Date, nil] The date of the balance to include in the letter.
# @param balance_date [Date, nil] The UTC date of the balance to include in the letter.
end

# @see Increase::Models::Export#balance_csv
Expand Down Expand Up @@ -403,13 +403,13 @@ class BookkeepingAccountBalanceCsv < Increase::Internal::Type::BaseModel
required :bookkeeping_account_id, String, nil?: true

# @!attribute on_or_after_date
# Filter balances to those on or after this date.
# Filter balances to those on or after this UTC date.
#
# @return [Date, nil]
required :on_or_after_date, Date, nil?: true

# @!attribute on_or_before_date
# Filter balances to those on or before this date.
# Filter balances to those on or before this UTC date.
#
# @return [Date, nil]
required :on_or_before_date, Date, nil?: true
Expand All @@ -420,9 +420,9 @@ class BookkeepingAccountBalanceCsv < Increase::Internal::Type::BaseModel
#
# @param bookkeeping_account_id [String, nil] Filter results by Bookkeeping Account.
#
# @param on_or_after_date [Date, nil] Filter balances to those on or after this date.
# @param on_or_after_date [Date, nil] Filter balances to those on or after this UTC date.
#
# @param on_or_before_date [Date, nil] Filter balances to those on or before this date.
# @param on_or_before_date [Date, nil] Filter balances to those on or before this UTC date.
end

# The category of the Export. We may add additional possible values for this enum
Expand Down Expand Up @@ -490,13 +490,13 @@ class DailyAccountBalanceCsv < Increase::Internal::Type::BaseModel
required :account_id, String, nil?: true

# @!attribute on_or_after_date
# Filter balances on or after this date.
# Filter balances on or after this UTC date.
#
# @return [Date, nil]
required :on_or_after_date, Date, nil?: true

# @!attribute on_or_before_date
# Filter balances on or before this date.
# Filter balances on or before this UTC date.
#
# @return [Date, nil]
required :on_or_before_date, Date, nil?: true
Expand All @@ -507,9 +507,9 @@ class DailyAccountBalanceCsv < Increase::Internal::Type::BaseModel
#
# @param account_id [String, nil] Filter results by Account.
#
# @param on_or_after_date [Date, nil] Filter balances on or after this date.
# @param on_or_after_date [Date, nil] Filter balances on or after this UTC date.
#
# @param on_or_before_date [Date, nil] Filter balances on or before this date.
# @param on_or_before_date [Date, nil] Filter balances on or before this UTC date.
end

# @see Increase::Models::Export#dashboard_table_csv
Expand Down
37 changes: 19 additions & 18 deletions lib/increase/models/export_create_params.rb
Original file line number Diff line number Diff line change
Expand Up @@ -187,10 +187,9 @@ class AccountStatementBai2 < Increase::Internal::Type::BaseModel
optional :account_id, String

# @!attribute effective_date
# The date to create a BAI2 report for. If not provided, the current date will be
# used. The timezone is UTC. If the current date is used, the report will include
# intraday balances, otherwise it will include end-of-day balances for the
# provided date.
# The UTC date to create a BAI2 report for. If not provided, the current date will
# be used. If the current date is used, the report will include intraday balances,
# otherwise it will include end-of-day balances for the provided date.
#
# @return [Date, nil]
optional :effective_date, Date
Expand All @@ -211,10 +210,9 @@ class AccountStatementBai2 < Increase::Internal::Type::BaseModel
# be included.
#
# @param effective_date [Date]
# The date to create a BAI2 report for. If not provided, the current date will be
# used. The timezone is UTC. If the current date is used, the report will include
# intraday balances, otherwise it will include end-of-day balances for the
# provided date.
# The UTC date to create a BAI2 report for. If not provided, the current date will
# be used. If the current date is used, the report will include intraday balances,
# otherwise it will include end-of-day balances for the provided date.
#
# @param program_id [String]
# The Program to create a BAI2 report for. If not provided, all open accounts will
Expand Down Expand Up @@ -274,7 +272,8 @@ class AccountVerificationLetter < Increase::Internal::Type::BaseModel
required :account_number_id, String

# @!attribute balance_date
# The date of the balance to include in the letter. Defaults to the current date.
# The UTC date of the balance to include in the letter. Defaults to the current
# date.
#
# @return [Date, nil]
optional :balance_date, Date
Expand All @@ -285,7 +284,9 @@ class AccountVerificationLetter < Increase::Internal::Type::BaseModel
#
# @param account_number_id [String] The Account Number to create a letter for.
#
# @param balance_date [Date] The date of the balance to include in the letter. Defaults to the current date.
# @param balance_date [Date]
# The UTC date of the balance to include in the letter. Defaults to the current
# date.
end

class BookkeepingAccountBalanceCsv < Increase::Internal::Type::BaseModel
Expand All @@ -297,13 +298,13 @@ class BookkeepingAccountBalanceCsv < Increase::Internal::Type::BaseModel
optional :bookkeeping_account_id, String

# @!attribute on_or_after_date
# Filter exported Balances to those on or after this date.
# Filter exported Balances to those on or after this UTC date.
#
# @return [Date, nil]
optional :on_or_after_date, Date

# @!attribute on_or_before_date
# Filter exported Balances to those on or before this date.
# Filter exported Balances to those on or before this UTC date.
#
# @return [Date, nil]
optional :on_or_before_date, Date
Expand All @@ -316,9 +317,9 @@ class BookkeepingAccountBalanceCsv < Increase::Internal::Type::BaseModel
# Filter exported Bookkeeping Account Balances to the specified Bookkeeping
# Account.
#
# @param on_or_after_date [Date] Filter exported Balances to those on or after this date.
# @param on_or_after_date [Date] Filter exported Balances to those on or after this UTC date.
#
# @param on_or_before_date [Date] Filter exported Balances to those on or before this date.
# @param on_or_before_date [Date] Filter exported Balances to those on or before this UTC date.
end

class DailyAccountBalanceCsv < Increase::Internal::Type::BaseModel
Expand All @@ -329,13 +330,13 @@ class DailyAccountBalanceCsv < Increase::Internal::Type::BaseModel
optional :account_id, String

# @!attribute on_or_after_date
# Filter exported Balances to those on or after this date.
# Filter exported Balances to those on or after this UTC date.
#
# @return [Date, nil]
optional :on_or_after_date, Date

# @!attribute on_or_before_date
# Filter exported Balances to those on or before this date.
# Filter exported Balances to those on or before this UTC date.
#
# @return [Date, nil]
optional :on_or_before_date, Date
Expand All @@ -346,9 +347,9 @@ class DailyAccountBalanceCsv < Increase::Internal::Type::BaseModel
#
# @param account_id [String] Filter exported Balances to the specified Account.
#
# @param on_or_after_date [Date] Filter exported Balances to those on or after this date.
# @param on_or_after_date [Date] Filter exported Balances to those on or after this UTC date.
#
# @param on_or_before_date [Date] Filter exported Balances to those on or before this date.
# @param on_or_before_date [Date] Filter exported Balances to those on or before this UTC date.
end

class EntityCsv < Increase::Internal::Type::BaseModel
Expand Down
Loading
Loading