Skip to content
Merged
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
12 changes: 2 additions & 10 deletions src/finch/resources/account.py
Original file line number Diff line number Diff line change
Expand Up @@ -36,11 +36,7 @@ def disconnect(
extra_body: Body | None = None,
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
) -> DisconnectResponse:
"""
Disconnect an employer from your application and invalidate all `access_token`s
associated with the employer. We require applications to implement the
Disconnect endpoint for billing and security purposes.
"""
"""Disconnect one or more `access_token`s from your application."""
return self._post(
"/disconnect",
options=make_request_options(
Expand Down Expand Up @@ -88,11 +84,7 @@ async def disconnect(
extra_body: Body | None = None,
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
) -> DisconnectResponse:
"""
Disconnect an employer from your application and invalidate all `access_token`s
associated with the employer. We require applications to implement the
Disconnect endpoint for billing and security purposes.
"""
"""Disconnect one or more `access_token`s from your application."""
return await self._post(
"/disconnect",
options=make_request_options(
Expand Down
56 changes: 14 additions & 42 deletions src/finch/resources/hris/benefits/benefits.py
Original file line number Diff line number Diff line change
Expand Up @@ -68,11 +68,10 @@ def create(
extra_body: Body | None = None,
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
) -> CreateCompanyBenefitsResponse:
"""
**Availability: Automated and Assisted Benefits providers**
"""Creates a new company-wide deduction or contribution.

Creates a new company-wide benefit. Please use the `/meta` endpoint to view
available types for each provider.
Please use the
`/providers` endpoint to view available types for each provider.

Args:
type: Type of benefit.
Expand Down Expand Up @@ -113,9 +112,7 @@ def retrieve(
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
) -> CompanyBenefit:
"""
**Availability: Automated Benefits providers only**

Lists benefit information for a given benefit
Lists deductions and contributions information for a given item

Args:
extra_headers: Send extra headers
Expand Down Expand Up @@ -149,9 +146,7 @@ def update(
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
) -> UpdateCompanyBenefitResponse:
"""
**Availability: Automated and Assisted Benefits providers**

Updates an existing company-wide benefit
Updates an existing company-wide deduction or contribution

Args:
description: Updated name or description.
Expand Down Expand Up @@ -185,11 +180,7 @@ def list(
extra_body: Body | None = None,
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
) -> SyncSinglePage[CompanyBenefit]:
"""
**Availability: Automated Benefits providers only**

List all company-wide benefits.
"""
"""List all company-wide deductions and contributions."""
return self._get_api_list(
"/employer/benefits",
page=SyncSinglePage[CompanyBenefit],
Expand All @@ -209,12 +200,7 @@ def list_supported_benefits(
extra_body: Body | None = None,
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
) -> SyncSinglePage[SupportedBenefit]:
"""
**Availability: Automated and Assisted Benefits providers**

Lists available types and configurations for the provider associated with the
access token.
"""
"""Get deductions metadata"""
return self._get_api_list(
"/employer/benefits/meta",
page=SyncSinglePage[SupportedBenefit],
Expand Down Expand Up @@ -251,11 +237,10 @@ async def create(
extra_body: Body | None = None,
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
) -> CreateCompanyBenefitsResponse:
"""
**Availability: Automated and Assisted Benefits providers**
"""Creates a new company-wide deduction or contribution.

Creates a new company-wide benefit. Please use the `/meta` endpoint to view
available types for each provider.
Please use the
`/providers` endpoint to view available types for each provider.

Args:
type: Type of benefit.
Expand Down Expand Up @@ -296,9 +281,7 @@ async def retrieve(
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
) -> CompanyBenefit:
"""
**Availability: Automated Benefits providers only**

Lists benefit information for a given benefit
Lists deductions and contributions information for a given item

Args:
extra_headers: Send extra headers
Expand Down Expand Up @@ -332,9 +315,7 @@ async def update(
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
) -> UpdateCompanyBenefitResponse:
"""
**Availability: Automated and Assisted Benefits providers**

Updates an existing company-wide benefit
Updates an existing company-wide deduction or contribution

Args:
description: Updated name or description.
Expand Down Expand Up @@ -368,11 +349,7 @@ def list(
extra_body: Body | None = None,
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
) -> AsyncPaginator[CompanyBenefit, AsyncSinglePage[CompanyBenefit]]:
"""
**Availability: Automated Benefits providers only**

List all company-wide benefits.
"""
"""List all company-wide deductions and contributions."""
return self._get_api_list(
"/employer/benefits",
page=AsyncSinglePage[CompanyBenefit],
Expand All @@ -392,12 +369,7 @@ def list_supported_benefits(
extra_body: Body | None = None,
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
) -> AsyncPaginator[SupportedBenefit, AsyncSinglePage[SupportedBenefit]]:
"""
**Availability: Automated and Assisted Benefits providers**

Lists available types and configurations for the provider associated with the
access token.
"""
"""Get deductions metadata"""
return self._get_api_list(
"/employer/benefits/meta",
page=AsyncSinglePage[SupportedBenefit],
Expand Down
54 changes: 16 additions & 38 deletions src/finch/resources/hris/benefits/individuals.py
Original file line number Diff line number Diff line change
Expand Up @@ -51,17 +51,12 @@ def enroll_many(
extra_body: Body | None = None,
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
) -> SyncSinglePage[EnrolledIndividual]:
"""
**Availability: Automated and Assisted Benefits providers**

Enroll an individual into a benefit. If the employee is already enrolled, the
enrollment amounts will be adjusted.

<!-- theme: warning -->
"""Enroll an individual into a deduction or contribution.

> Making changes to an individual's benefits may have tax consequences based on
> IRS regulations. Please consult a tax expert to ensure all changes being made
> to the system are compliant with local, state, and federal law.
This is an overwrite
operation. If the employee is already enrolled, the enrollment amounts will be
adjusted. Making the same request multiple times will not create new
enrollments, but will continue to set the state of the existing enrollment.

Args:
individuals: Array of the individual_id to enroll and a configuration object.
Expand Down Expand Up @@ -99,9 +94,7 @@ def enrolled_ids(
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
) -> IndividualEnrolledIDsResponse:
"""
**Availability: Automated Benefits providers only**

Lists individuals currently enrolled in a given benefit.
Lists individuals currently enrolled in a given deduction.

Args:
extra_headers: Send extra headers
Expand Down Expand Up @@ -135,9 +128,7 @@ def retrieve_many_benefits(
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
) -> SyncSinglePage[IndividualBenefit]:
"""
**Availability: Automated Benefits providers only**

Get enrolled benefit information for the given individuals.
Get enrollment information for the given individuals.

Args:
individual_ids: comma-delimited list of stable Finch uuids for each individual. If empty,
Expand Down Expand Up @@ -182,9 +173,7 @@ def unenroll_many(
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
) -> SyncSinglePage[UnenrolledIndividual]:
"""
**Availability: Automated and Assisted Benefits providers**

Unenroll individuals from a benefit
Unenroll individuals from a deduction or contribution

Args:
individual_ids: Array of individual_ids to unenroll.
Expand Down Expand Up @@ -234,17 +223,12 @@ def enroll_many(
extra_body: Body | None = None,
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
) -> AsyncPaginator[EnrolledIndividual, AsyncSinglePage[EnrolledIndividual]]:
"""
**Availability: Automated and Assisted Benefits providers**

Enroll an individual into a benefit. If the employee is already enrolled, the
enrollment amounts will be adjusted.

<!-- theme: warning -->
"""Enroll an individual into a deduction or contribution.

> Making changes to an individual's benefits may have tax consequences based on
> IRS regulations. Please consult a tax expert to ensure all changes being made
> to the system are compliant with local, state, and federal law.
This is an overwrite
operation. If the employee is already enrolled, the enrollment amounts will be
adjusted. Making the same request multiple times will not create new
enrollments, but will continue to set the state of the existing enrollment.

Args:
individuals: Array of the individual_id to enroll and a configuration object.
Expand Down Expand Up @@ -282,9 +266,7 @@ async def enrolled_ids(
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
) -> IndividualEnrolledIDsResponse:
"""
**Availability: Automated Benefits providers only**

Lists individuals currently enrolled in a given benefit.
Lists individuals currently enrolled in a given deduction.

Args:
extra_headers: Send extra headers
Expand Down Expand Up @@ -318,9 +300,7 @@ def retrieve_many_benefits(
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
) -> AsyncPaginator[IndividualBenefit, AsyncSinglePage[IndividualBenefit]]:
"""
**Availability: Automated Benefits providers only**

Get enrolled benefit information for the given individuals.
Get enrollment information for the given individuals.

Args:
individual_ids: comma-delimited list of stable Finch uuids for each individual. If empty,
Expand Down Expand Up @@ -365,9 +345,7 @@ def unenroll_many(
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
) -> AsyncPaginator[UnenrolledIndividual, AsyncSinglePage[UnenrolledIndividual]]:
"""
**Availability: Automated and Assisted Benefits providers**

Unenroll individuals from a benefit
Unenroll individuals from a deduction or contribution

Args:
individual_ids: Array of individual_ids to unenroll.
Expand Down
8 changes: 0 additions & 8 deletions src/finch/resources/hris/employments.py
Original file line number Diff line number Diff line change
Expand Up @@ -45,10 +45,6 @@ def retrieve_many(
"""
Read individual employment and income data

Note: Income information is returned as reported by the provider. This may not
always be annualized income, but may be in units of bi-weekly, semi-monthly,
daily, etc, depending on what information the provider returns.

Args:
requests: The array of batch requests.

Expand Down Expand Up @@ -95,10 +91,6 @@ def retrieve_many(
"""
Read individual employment and income data

Note: Income information is returned as reported by the provider. This may not
always be annualized income, but may be in units of bi-weekly, semi-monthly,
daily, etc, depending on what information the provider returns.

Args:
requests: The array of batch requests.

Expand Down
4 changes: 2 additions & 2 deletions src/finch/resources/hris/pay_statements.py
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ def retrieve_many(
Read detailed pay statements for each individual.

Deduction and contribution types are supported by the payroll systems that
support Benefits.
supports Benefits.

Args:
requests: The array of batch requests.
Expand Down Expand Up @@ -97,7 +97,7 @@ def retrieve_many(
Read detailed pay statements for each individual.

Deduction and contribution types are supported by the payroll systems that
support Benefits.
supports Benefits.

Args:
requests: The array of batch requests.
Expand Down