From e6b377f7c690f3ee47d59cbd70f67e726f7c989e Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Tue, 24 Mar 2026 15:23:53 +0000 Subject: [PATCH 1/5] codegen metadata --- .stats.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.stats.yml b/.stats.yml index 23ff028..3179d05 100644 --- a/.stats.yml +++ b/.stats.yml @@ -1,4 +1,4 @@ configured_endpoints: 14 openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/vitable%2Fvitable-connect-96179d55665afbff5aca73845920de0597dfcc151a97fabf93a4cc818d7859eb.yml openapi_spec_hash: 4eb9796fe4adb7074b6df7ffdc6caa8d -config_hash: 5c13804b8ff0767820e2d2422eaafa84 +config_hash: 392cd8e22829fb71bec02e5b3963d857 From f2ce826ec28580b76467b9d10eb2779822954ccc Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Tue, 24 Mar 2026 15:24:23 +0000 Subject: [PATCH 2/5] codegen metadata --- .stats.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.stats.yml b/.stats.yml index 3179d05..9aa4351 100644 --- a/.stats.yml +++ b/.stats.yml @@ -1,4 +1,4 @@ configured_endpoints: 14 openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/vitable%2Fvitable-connect-96179d55665afbff5aca73845920de0597dfcc151a97fabf93a4cc818d7859eb.yml openapi_spec_hash: 4eb9796fe4adb7074b6df7ffdc6caa8d -config_hash: 392cd8e22829fb71bec02e5b3963d857 +config_hash: d2ce0848d5b4f2e1461c01f6eafd9b19 From f190ebfc6a6fb2885813ca931618c615b815d9c5 Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Wed, 25 Mar 2026 03:29:22 +0000 Subject: [PATCH 3/5] chore(ci): skip lint on metadata-only changes Note that we still want to run tests, as these depend on the metadata. --- .github/workflows/ci.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 742cba0..a8b3b38 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -24,7 +24,8 @@ jobs: runs-on: ${{ github.repository == 'stainless-sdks/vitable-connect-ruby' && 'depot-ubuntu-24.04' || 'ubuntu-latest' }} if: |- github.repository == 'stainless-sdks/vitable-connect-ruby' && - (github.event_name == 'push' || github.event.pull_request.head.repo.fork) + (github.event_name == 'push' || github.event.pull_request.head.repo.fork) && + (github.event_name != 'push' || github.event.head_commit.message != 'codegen metadata') steps: - uses: actions/checkout@v6 - name: Set up Ruby From f91931100038a62655c5e06eaa86271babc56d7a Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Wed, 25 Mar 2026 19:41:57 +0000 Subject: [PATCH 4/5] feat(api): api update --- .stats.yml | 4 +- lib/vitable_connect/models/employee.rb | 103 ++++++++++- .../models/webhook_event_list_params.rb | 6 +- lib/vitable_connect/resources/employees.rb | 4 +- lib/vitable_connect/resources/employers.rb | 4 +- rbi/vitable_connect/models/employee.rbi | 175 ++++++++++++++++++ .../models/webhook_event_list_params.rbi | 14 +- rbi/vitable_connect/resources/employees.rbi | 4 +- rbi/vitable_connect/resources/employers.rbi | 4 +- .../resources/webhook_events.rbi | 2 +- sig/vitable_connect/models/employee.rbs | 74 ++++++++ .../models/webhook_event_list_params.rbs | 4 +- .../resources/employers_test.rb | 1 + 13 files changed, 379 insertions(+), 20 deletions(-) diff --git a/.stats.yml b/.stats.yml index 9aa4351..215938e 100644 --- a/.stats.yml +++ b/.stats.yml @@ -1,4 +1,4 @@ configured_endpoints: 14 -openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/vitable%2Fvitable-connect-96179d55665afbff5aca73845920de0597dfcc151a97fabf93a4cc818d7859eb.yml -openapi_spec_hash: 4eb9796fe4adb7074b6df7ffdc6caa8d +openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/vitable%2Fvitable-connect-e61b9afbfd2525af28aea98d7b106979d1fa2e15af61a2a14d129d64ed6a0a77.yml +openapi_spec_hash: 0ff58ff57f78739499e3781e6bf00ba1 config_hash: d2ce0848d5b4f2e1461c01f6eafd9b19 diff --git a/lib/vitable_connect/models/employee.rb b/lib/vitable_connect/models/employee.rb index 0808ad6..403b82b 100644 --- a/lib/vitable_connect/models/employee.rb +++ b/lib/vitable_connect/models/employee.rb @@ -15,6 +15,13 @@ class Employee < VitableConnect::Internal::Type::BaseModel # @return [Date] required :date_of_birth, Date + # @!attribute deductions + # Payroll deductions from the most recent statement period. Replaced when a new + # statement is generated. + # + # @return [Array] + required :deductions, -> { VitableConnect::Internal::Type::ArrayOf[VitableConnect::Employee::Deduction] } + # @!attribute email # Email address # @@ -119,7 +126,7 @@ class Employee < VitableConnect::Internal::Type::BaseModel required :status, String end - # @!method initialize(id:, created_at:, date_of_birth:, email:, enrollments:, first_name:, last_name:, member_id:, status:, updated_at:, address: nil, employee_class: nil, gender: nil, hire_date: nil, phone: nil, reference_id: nil, suffix: nil, termination_date: nil) + # @!method initialize(id:, created_at:, date_of_birth:, deductions:, email:, enrollments:, first_name:, last_name:, member_id:, status:, updated_at:, address: nil, employee_class: nil, gender: nil, hire_date: nil, phone: nil, reference_id: nil, suffix: nil, termination_date: nil) # Some parameter documentations has been truncated, see # {VitableConnect::Models::Employee} for more details. # @@ -129,6 +136,8 @@ class Employee < VitableConnect::Internal::Type::BaseModel # # @param date_of_birth [Date] Date of birth (YYYY-MM-DD) # + # @param deductions [Array] Payroll deductions from the most recent statement period. Replaced when a new st + # # @param email [String] Email address # # @param enrollments [Array] Benefit enrollments for this employee @@ -159,6 +168,98 @@ class Employee < VitableConnect::Internal::Type::BaseModel # # @param termination_date [Date, nil] Employee's termination date, if terminated + class Deduction < VitableConnect::Internal::Type::BaseModel + # @!attribute benefit_name + # Name of the benefit plan + # + # @return [String] + required :benefit_name, String + + # @!attribute deduction_amount_in_cents + # Employee deduction amount in cents + # + # @return [Integer] + required :deduction_amount_in_cents, Integer + + # @!attribute deduction_category + # Deduction category (reserved for future use) + # + # @return [String, nil] + required :deduction_category, String, nil?: true + + # @!attribute frequency + # - `monthly` - Monthly + # + # @return [Symbol, VitableConnect::Models::Employee::Deduction::Frequency] + required :frequency, enum: -> { VitableConnect::Employee::Deduction::Frequency } + + # @!attribute period_end_date + # Period end date (YYYY-MM-DD) + # + # @return [Date] + required :period_end_date, Date + + # @!attribute period_start_date + # Period start date (YYYY-MM-DD) + # + # @return [Date] + required :period_start_date, Date + + # @!attribute tax_classification + # - `Unknown` - Unknown + # - `Pre-tax` - Pre Tax + # - `Post-tax` - Post Tax + # + # @return [Symbol, VitableConnect::Models::Employee::Deduction::TaxClassification] + required :tax_classification, enum: -> { VitableConnect::Employee::Deduction::TaxClassification } + + # @!method initialize(benefit_name:, deduction_amount_in_cents:, deduction_category:, frequency:, period_end_date:, period_start_date:, tax_classification:) + # Some parameter documentations has been truncated, see + # {VitableConnect::Models::Employee::Deduction} for more details. + # + # @param benefit_name [String] Name of the benefit plan + # + # @param deduction_amount_in_cents [Integer] Employee deduction amount in cents + # + # @param deduction_category [String, nil] Deduction category (reserved for future use) + # + # @param frequency [Symbol, VitableConnect::Models::Employee::Deduction::Frequency] - `monthly` - Monthly + # + # @param period_end_date [Date] Period end date (YYYY-MM-DD) + # + # @param period_start_date [Date] Period start date (YYYY-MM-DD) + # + # @param tax_classification [Symbol, VitableConnect::Models::Employee::Deduction::TaxClassification] - `Unknown` - Unknown + + # - `monthly` - Monthly + # + # @see VitableConnect::Models::Employee::Deduction#frequency + module Frequency + extend VitableConnect::Internal::Type::Enum + + MONTHLY = :monthly + + # @!method self.values + # @return [Array] + end + + # - `Unknown` - Unknown + # - `Pre-tax` - Pre Tax + # - `Post-tax` - Post Tax + # + # @see VitableConnect::Models::Employee::Deduction#tax_classification + module TaxClassification + extend VitableConnect::Internal::Type::Enum + + UNKNOWN = :Unknown + PRE_TAX = :"Pre-tax" + POST_TAX = :"Post-tax" + + # @!method self.values + # @return [Array] + end + end + class Enrollment < VitableConnect::Internal::Type::BaseModel # @!attribute status # - `pending` - Pending diff --git a/lib/vitable_connect/models/webhook_event_list_params.rb b/lib/vitable_connect/models/webhook_event_list_params.rb index afe9a58..0b9ba6a 100644 --- a/lib/vitable_connect/models/webhook_event_list_params.rb +++ b/lib/vitable_connect/models/webhook_event_list_params.rb @@ -27,8 +27,8 @@ class WebhookEventListParams < VitableConnect::Internal::Type::BaseModel # - `employee.eligibility_granted` - Employee Eligibility Granted # - `employee.eligibility_terminated` - Employee Eligibility Terminated # - `employee.deactivated` - Employee Deactivated - # - `payroll_deduction.created` - Payroll Deduction Created # - `employer.eligibility_policy_created` - Employer Eligibility Policy Created + # - `employee.deduction_created` - Employee Deduction Created # # @return [Symbol, VitableConnect::Models::WebhookEventListParams::EventName, nil] optional :event_name, enum: -> { VitableConnect::WebhookEventListParams::EventName } @@ -90,8 +90,8 @@ class WebhookEventListParams < VitableConnect::Internal::Type::BaseModel # - `employee.eligibility_granted` - Employee Eligibility Granted # - `employee.eligibility_terminated` - Employee Eligibility Terminated # - `employee.deactivated` - Employee Deactivated - # - `payroll_deduction.created` - Payroll Deduction Created # - `employer.eligibility_policy_created` - Employer Eligibility Policy Created + # - `employee.deduction_created` - Employee Deduction Created module EventName extend VitableConnect::Internal::Type::Enum @@ -104,8 +104,8 @@ module EventName EMPLOYEE_ELIGIBILITY_GRANTED = :"employee.eligibility_granted" EMPLOYEE_ELIGIBILITY_TERMINATED = :"employee.eligibility_terminated" EMPLOYEE_DEACTIVATED = :"employee.deactivated" - PAYROLL_DEDUCTION_CREATED = :"payroll_deduction.created" EMPLOYER_ELIGIBILITY_POLICY_CREATED = :"employer.eligibility_policy_created" + EMPLOYEE_DEDUCTION_CREATED = :"employee.deduction_created" # @!method self.values # @return [Array] diff --git a/lib/vitable_connect/resources/employees.rb b/lib/vitable_connect/resources/employees.rb index 8843d33..d4a3446 100644 --- a/lib/vitable_connect/resources/employees.rb +++ b/lib/vitable_connect/resources/employees.rb @@ -4,7 +4,9 @@ module VitableConnect module Resources class Employees # Retrieves detailed information for a specific employee by ID. Returns employee - # details including personal information and employment status. + # details including personal information, employment status, and payroll + # deductions from the most recent statement period. Deductions reflect a snapshot + # of the current period and are replaced when a new statement is generated. # # @overload retrieve(employee_id, request_options: {}) # diff --git a/lib/vitable_connect/resources/employers.rb b/lib/vitable_connect/resources/employers.rb index 398ebde..631e0fc 100644 --- a/lib/vitable_connect/resources/employers.rb +++ b/lib/vitable_connect/resources/employers.rb @@ -119,7 +119,9 @@ def create_benefit_eligibility_policy(employer_id, params) end # Retrieves a paginated list of all employees for a specific employer. Results are - # paginated using page and limit parameters. + # paginated using page and limit parameters. Each employee includes payroll + # deductions from the most recent statement period. When a new deduction statement + # is generated, previous period deductions are replaced. # # @overload list_employees(employer_id, limit: nil, page: nil, request_options: {}) # diff --git a/rbi/vitable_connect/models/employee.rbi b/rbi/vitable_connect/models/employee.rbi index 613f1b9..afca501 100644 --- a/rbi/vitable_connect/models/employee.rbi +++ b/rbi/vitable_connect/models/employee.rbi @@ -16,6 +16,11 @@ module VitableConnect sig { returns(Date) } attr_accessor :date_of_birth + # Payroll deductions from the most recent statement period. Replaced when a new + # statement is generated. + sig { returns(T::Array[VitableConnect::Employee::Deduction]) } + attr_accessor :deductions + # Email address sig { returns(String) } attr_accessor :email @@ -97,6 +102,7 @@ module VitableConnect id: String, created_at: Time, date_of_birth: Date, + deductions: T::Array[VitableConnect::Employee::Deduction::OrHash], email: String, enrollments: T::Array[VitableConnect::Employee::Enrollment::OrHash], first_name: String, @@ -121,6 +127,9 @@ module VitableConnect created_at:, # Date of birth (YYYY-MM-DD) date_of_birth:, + # Payroll deductions from the most recent statement period. Replaced when a new + # statement is generated. + deductions:, # Email address email:, # Benefit enrollments for this employee @@ -165,6 +174,7 @@ module VitableConnect id: String, created_at: Time, date_of_birth: Date, + deductions: T::Array[VitableConnect::Employee::Deduction], email: String, enrollments: T::Array[VitableConnect::Employee::Enrollment], first_name: String, @@ -187,6 +197,171 @@ module VitableConnect def to_hash end + class Deduction < VitableConnect::Internal::Type::BaseModel + OrHash = + T.type_alias do + T.any( + VitableConnect::Employee::Deduction, + VitableConnect::Internal::AnyHash + ) + end + + # Name of the benefit plan + sig { returns(String) } + attr_accessor :benefit_name + + # Employee deduction amount in cents + sig { returns(Integer) } + attr_accessor :deduction_amount_in_cents + + # Deduction category (reserved for future use) + sig { returns(T.nilable(String)) } + attr_accessor :deduction_category + + # - `monthly` - Monthly + sig do + returns(VitableConnect::Employee::Deduction::Frequency::TaggedSymbol) + end + attr_accessor :frequency + + # Period end date (YYYY-MM-DD) + sig { returns(Date) } + attr_accessor :period_end_date + + # Period start date (YYYY-MM-DD) + sig { returns(Date) } + attr_accessor :period_start_date + + # - `Unknown` - Unknown + # - `Pre-tax` - Pre Tax + # - `Post-tax` - Post Tax + sig do + returns( + VitableConnect::Employee::Deduction::TaxClassification::TaggedSymbol + ) + end + attr_accessor :tax_classification + + sig do + params( + benefit_name: String, + deduction_amount_in_cents: Integer, + deduction_category: T.nilable(String), + frequency: VitableConnect::Employee::Deduction::Frequency::OrSymbol, + period_end_date: Date, + period_start_date: Date, + tax_classification: + VitableConnect::Employee::Deduction::TaxClassification::OrSymbol + ).returns(T.attached_class) + end + def self.new( + # Name of the benefit plan + benefit_name:, + # Employee deduction amount in cents + deduction_amount_in_cents:, + # Deduction category (reserved for future use) + deduction_category:, + # - `monthly` - Monthly + frequency:, + # Period end date (YYYY-MM-DD) + period_end_date:, + # Period start date (YYYY-MM-DD) + period_start_date:, + # - `Unknown` - Unknown + # - `Pre-tax` - Pre Tax + # - `Post-tax` - Post Tax + tax_classification: + ) + end + + sig do + override.returns( + { + benefit_name: String, + deduction_amount_in_cents: Integer, + deduction_category: T.nilable(String), + frequency: + VitableConnect::Employee::Deduction::Frequency::TaggedSymbol, + period_end_date: Date, + period_start_date: Date, + tax_classification: + VitableConnect::Employee::Deduction::TaxClassification::TaggedSymbol + } + ) + end + def to_hash + end + + # - `monthly` - Monthly + module Frequency + extend VitableConnect::Internal::Type::Enum + + TaggedSymbol = + T.type_alias do + T.all(Symbol, VitableConnect::Employee::Deduction::Frequency) + end + OrSymbol = T.type_alias { T.any(Symbol, String) } + + MONTHLY = + T.let( + :monthly, + VitableConnect::Employee::Deduction::Frequency::TaggedSymbol + ) + + sig do + override.returns( + T::Array[ + VitableConnect::Employee::Deduction::Frequency::TaggedSymbol + ] + ) + end + def self.values + end + end + + # - `Unknown` - Unknown + # - `Pre-tax` - Pre Tax + # - `Post-tax` - Post Tax + module TaxClassification + extend VitableConnect::Internal::Type::Enum + + TaggedSymbol = + T.type_alias do + T.all( + Symbol, + VitableConnect::Employee::Deduction::TaxClassification + ) + end + OrSymbol = T.type_alias { T.any(Symbol, String) } + + UNKNOWN = + T.let( + :Unknown, + VitableConnect::Employee::Deduction::TaxClassification::TaggedSymbol + ) + PRE_TAX = + T.let( + :"Pre-tax", + VitableConnect::Employee::Deduction::TaxClassification::TaggedSymbol + ) + POST_TAX = + T.let( + :"Post-tax", + VitableConnect::Employee::Deduction::TaxClassification::TaggedSymbol + ) + + sig do + override.returns( + T::Array[ + VitableConnect::Employee::Deduction::TaxClassification::TaggedSymbol + ] + ) + end + def self.values + end + end + end + class Enrollment < VitableConnect::Internal::Type::BaseModel OrHash = T.type_alias do diff --git a/rbi/vitable_connect/models/webhook_event_list_params.rbi b/rbi/vitable_connect/models/webhook_event_list_params.rbi index 1d0db89..c9e49ba 100644 --- a/rbi/vitable_connect/models/webhook_event_list_params.rbi +++ b/rbi/vitable_connect/models/webhook_event_list_params.rbi @@ -35,8 +35,8 @@ module VitableConnect # - `employee.eligibility_granted` - Employee Eligibility Granted # - `employee.eligibility_terminated` - Employee Eligibility Terminated # - `employee.deactivated` - Employee Deactivated - # - `payroll_deduction.created` - Payroll Deduction Created # - `employer.eligibility_policy_created` - Employer Eligibility Policy Created + # - `employee.deduction_created` - Employee Deduction Created sig do returns( T.nilable(VitableConnect::WebhookEventListParams::EventName::OrSymbol) @@ -121,8 +121,8 @@ module VitableConnect # - `employee.eligibility_granted` - Employee Eligibility Granted # - `employee.eligibility_terminated` - Employee Eligibility Terminated # - `employee.deactivated` - Employee Deactivated - # - `payroll_deduction.created` - Payroll Deduction Created # - `employer.eligibility_policy_created` - Employer Eligibility Policy Created + # - `employee.deduction_created` - Employee Deduction Created event_name: nil, # Items per page (default: 20, max: 100) limit: nil, @@ -168,8 +168,8 @@ module VitableConnect # - `employee.eligibility_granted` - Employee Eligibility Granted # - `employee.eligibility_terminated` - Employee Eligibility Terminated # - `employee.deactivated` - Employee Deactivated - # - `payroll_deduction.created` - Payroll Deduction Created # - `employer.eligibility_policy_created` - Employer Eligibility Policy Created + # - `employee.deduction_created` - Employee Deduction Created module EventName extend VitableConnect::Internal::Type::Enum @@ -224,14 +224,14 @@ module VitableConnect :"employee.deactivated", VitableConnect::WebhookEventListParams::EventName::TaggedSymbol ) - PAYROLL_DEDUCTION_CREATED = + EMPLOYER_ELIGIBILITY_POLICY_CREATED = T.let( - :"payroll_deduction.created", + :"employer.eligibility_policy_created", VitableConnect::WebhookEventListParams::EventName::TaggedSymbol ) - EMPLOYER_ELIGIBILITY_POLICY_CREATED = + EMPLOYEE_DEDUCTION_CREATED = T.let( - :"employer.eligibility_policy_created", + :"employee.deduction_created", VitableConnect::WebhookEventListParams::EventName::TaggedSymbol ) diff --git a/rbi/vitable_connect/resources/employees.rbi b/rbi/vitable_connect/resources/employees.rbi index cafe294..de327c8 100644 --- a/rbi/vitable_connect/resources/employees.rbi +++ b/rbi/vitable_connect/resources/employees.rbi @@ -4,7 +4,9 @@ module VitableConnect module Resources class Employees # Retrieves detailed information for a specific employee by ID. Returns employee - # details including personal information and employment status. + # details including personal information, employment status, and payroll + # deductions from the most recent statement period. Deductions reflect a snapshot + # of the current period and are replaced when a new statement is generated. sig do params( employee_id: String, diff --git a/rbi/vitable_connect/resources/employers.rbi b/rbi/vitable_connect/resources/employers.rbi index cb0d366..e5de3b6 100644 --- a/rbi/vitable_connect/resources/employers.rbi +++ b/rbi/vitable_connect/resources/employers.rbi @@ -95,7 +95,9 @@ module VitableConnect end # Retrieves a paginated list of all employees for a specific employer. Results are - # paginated using page and limit parameters. + # paginated using page and limit parameters. Each employee includes payroll + # deductions from the most recent statement period. When a new deduction statement + # is generated, previous period deductions are replaced. sig do params( employer_id: String, diff --git a/rbi/vitable_connect/resources/webhook_events.rbi b/rbi/vitable_connect/resources/webhook_events.rbi index fb91bcb..5b522c7 100644 --- a/rbi/vitable_connect/resources/webhook_events.rbi +++ b/rbi/vitable_connect/resources/webhook_events.rbi @@ -44,8 +44,8 @@ module VitableConnect # - `employee.eligibility_granted` - Employee Eligibility Granted # - `employee.eligibility_terminated` - Employee Eligibility Terminated # - `employee.deactivated` - Employee Deactivated - # - `payroll_deduction.created` - Payroll Deduction Created # - `employer.eligibility_policy_created` - Employer Eligibility Policy Created + # - `employee.deduction_created` - Employee Deduction Created event_name: nil, # Items per page (default: 20, max: 100) limit: nil, diff --git a/sig/vitable_connect/models/employee.rbs b/sig/vitable_connect/models/employee.rbs index e01b020..3918f5d 100644 --- a/sig/vitable_connect/models/employee.rbs +++ b/sig/vitable_connect/models/employee.rbs @@ -5,6 +5,7 @@ module VitableConnect id: String, created_at: Time, date_of_birth: Date, + deductions: ::Array[VitableConnect::Employee::Deduction], email: String, enrollments: ::Array[VitableConnect::Employee::Enrollment], first_name: String, @@ -27,6 +28,8 @@ module VitableConnect attr_accessor date_of_birth: Date + attr_accessor deductions: ::Array[VitableConnect::Employee::Deduction] + attr_accessor email: String attr_accessor enrollments: ::Array[VitableConnect::Employee::Enrollment] @@ -63,6 +66,7 @@ module VitableConnect id: String, created_at: Time, date_of_birth: Date, + deductions: ::Array[VitableConnect::Employee::Deduction], email: String, enrollments: ::Array[VitableConnect::Employee::Enrollment], first_name: String, @@ -84,6 +88,7 @@ module VitableConnect id: String, created_at: Time, date_of_birth: Date, + deductions: ::Array[VitableConnect::Employee::Deduction], email: String, enrollments: ::Array[VitableConnect::Employee::Enrollment], first_name: String, @@ -101,6 +106,75 @@ module VitableConnect termination_date: Date? } + type deduction = + { + benefit_name: String, + deduction_amount_in_cents: Integer, + deduction_category: String?, + frequency: VitableConnect::Models::Employee::Deduction::frequency, + period_end_date: Date, + period_start_date: Date, + tax_classification: VitableConnect::Models::Employee::Deduction::tax_classification + } + + class Deduction < VitableConnect::Internal::Type::BaseModel + attr_accessor benefit_name: String + + attr_accessor deduction_amount_in_cents: Integer + + attr_accessor deduction_category: String? + + attr_accessor frequency: VitableConnect::Models::Employee::Deduction::frequency + + attr_accessor period_end_date: Date + + attr_accessor period_start_date: Date + + attr_accessor tax_classification: VitableConnect::Models::Employee::Deduction::tax_classification + + def initialize: ( + benefit_name: String, + deduction_amount_in_cents: Integer, + deduction_category: String?, + frequency: VitableConnect::Models::Employee::Deduction::frequency, + period_end_date: Date, + period_start_date: Date, + tax_classification: VitableConnect::Models::Employee::Deduction::tax_classification + ) -> void + + def to_hash: -> { + benefit_name: String, + deduction_amount_in_cents: Integer, + deduction_category: String?, + frequency: VitableConnect::Models::Employee::Deduction::frequency, + period_end_date: Date, + period_start_date: Date, + tax_classification: VitableConnect::Models::Employee::Deduction::tax_classification + } + + type frequency = :monthly + + module Frequency + extend VitableConnect::Internal::Type::Enum + + MONTHLY: :monthly + + def self?.values: -> ::Array[VitableConnect::Models::Employee::Deduction::frequency] + end + + type tax_classification = :Unknown | :"Pre-tax" | :"Post-tax" + + module TaxClassification + extend VitableConnect::Internal::Type::Enum + + UNKNOWN: :Unknown + PRE_TAX: :"Pre-tax" + POST_TAX: :"Post-tax" + + def self?.values: -> ::Array[VitableConnect::Models::Employee::Deduction::tax_classification] + end + end + type enrollment = { id: String, diff --git a/sig/vitable_connect/models/webhook_event_list_params.rbs b/sig/vitable_connect/models/webhook_event_list_params.rbs index 3ef3223..6d932ad 100644 --- a/sig/vitable_connect/models/webhook_event_list_params.rbs +++ b/sig/vitable_connect/models/webhook_event_list_params.rbs @@ -80,8 +80,8 @@ module VitableConnect | :"employee.eligibility_granted" | :"employee.eligibility_terminated" | :"employee.deactivated" - | :"payroll_deduction.created" | :"employer.eligibility_policy_created" + | :"employee.deduction_created" module EventName extend VitableConnect::Internal::Type::Enum @@ -95,8 +95,8 @@ module VitableConnect EMPLOYEE_ELIGIBILITY_GRANTED: :"employee.eligibility_granted" EMPLOYEE_ELIGIBILITY_TERMINATED: :"employee.eligibility_terminated" EMPLOYEE_DEACTIVATED: :"employee.deactivated" - PAYROLL_DEDUCTION_CREATED: :"payroll_deduction.created" EMPLOYER_ELIGIBILITY_POLICY_CREATED: :"employer.eligibility_policy_created" + EMPLOYEE_DEDUCTION_CREATED: :"employee.deduction_created" def self?.values: -> ::Array[VitableConnect::Models::WebhookEventListParams::event_name] end diff --git a/test/vitable_connect/resources/employers_test.rb b/test/vitable_connect/resources/employers_test.rb index 979e8e8..670090c 100644 --- a/test/vitable_connect/resources/employers_test.rb +++ b/test/vitable_connect/resources/employers_test.rb @@ -119,6 +119,7 @@ def test_list_employees id: String, created_at: Time, date_of_birth: Date, + deductions: ^(VitableConnect::Internal::Type::ArrayOf[VitableConnect::Employee::Deduction]), email: String, enrollments: ^(VitableConnect::Internal::Type::ArrayOf[VitableConnect::Employee::Enrollment]), first_name: String, From 97f0815c07a5b3f9b99e2deeab59048765efe33a Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Wed, 25 Mar 2026 19:42:38 +0000 Subject: [PATCH 5/5] release: 0.2.0 --- .release-please-manifest.json | 2 +- CHANGELOG.md | 13 +++++++++++++ Gemfile.lock | 2 +- README.md | 2 +- lib/vitable_connect/version.rb | 2 +- 5 files changed, 17 insertions(+), 4 deletions(-) diff --git a/.release-please-manifest.json b/.release-please-manifest.json index 3d2ac0b..10f3091 100644 --- a/.release-please-manifest.json +++ b/.release-please-manifest.json @@ -1,3 +1,3 @@ { - ".": "0.1.0" + ".": "0.2.0" } \ No newline at end of file diff --git a/CHANGELOG.md b/CHANGELOG.md index 61b5fca..f3f7379 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,18 @@ # Changelog +## 0.2.0 (2026-03-25) + +Full Changelog: [v0.1.0...v0.2.0](https://github.com/Vitable-Inc/vitable-connect-ruby/compare/v0.1.0...v0.2.0) + +### Features + +* **api:** api update ([f919311](https://github.com/Vitable-Inc/vitable-connect-ruby/commit/f91931100038a62655c5e06eaa86271babc56d7a)) + + +### Chores + +* **ci:** skip lint on metadata-only changes ([f190ebf](https://github.com/Vitable-Inc/vitable-connect-ruby/commit/f190ebfc6a6fb2885813ca931618c615b815d9c5)) + ## 0.1.0 (2026-03-24) Full Changelog: [v0.0.1...v0.1.0](https://github.com/Vitable-Inc/vitable-connect-ruby/compare/v0.0.1...v0.1.0) diff --git a/Gemfile.lock b/Gemfile.lock index c98a916..61cb3ed 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -11,7 +11,7 @@ GIT PATH remote: . specs: - vitable-connect (0.1.0) + vitable-connect (0.2.0) cgi connection_pool diff --git a/README.md b/README.md index 7d6ef26..099f713 100644 --- a/README.md +++ b/README.md @@ -17,7 +17,7 @@ To use this gem, install via Bundler by adding the following to your application ```ruby -gem "vitable-connect", "~> 0.1.0" +gem "vitable-connect", "~> 0.2.0" ``` diff --git a/lib/vitable_connect/version.rb b/lib/vitable_connect/version.rb index d1d9fa5..090f698 100644 --- a/lib/vitable_connect/version.rb +++ b/lib/vitable_connect/version.rb @@ -1,5 +1,5 @@ # frozen_string_literal: true module VitableConnect - VERSION = "0.1.0" + VERSION = "0.2.0" end