Skip to content
Open
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
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
688 changes: 579 additions & 109 deletions .openapi-generator/FILES

Large diffs are not rendered by default.

715 changes: 587 additions & 128 deletions README.md

Large diffs are not rendered by default.

1,642 changes: 1,388 additions & 254 deletions bamboohr_sdk/__init__.py

Large diffs are not rendered by default.

12 changes: 11 additions & 1 deletion bamboohr_sdk/api/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,23 +2,33 @@

# import apis into api package
from bamboohr_sdk.api.account_information_api import AccountInformationApi
from bamboohr_sdk.api.alert_api import AlertApi
from bamboohr_sdk.api.alert_configurations_api import AlertConfigurationsApi
from bamboohr_sdk.api.applicant_tracking_api import ApplicantTrackingApi
from bamboohr_sdk.api.benefits_api import BenefitsApi
from bamboohr_sdk.api.company_api import CompanyApi
from bamboohr_sdk.api.company_files_api import CompanyFilesApi
from bamboohr_sdk.api.company_profile_api import CompanyProfileApi
from bamboohr_sdk.api.compensation_api import CompensationApi
from bamboohr_sdk.api.compensation_benchmarking_api import CompensationBenchmarkingApi
from bamboohr_sdk.api.compensation_planning_api import CompensationPlanningApi
from bamboohr_sdk.api.custom_reports_api import CustomReportsApi
from bamboohr_sdk.api.datasets_api import DatasetsApi
from bamboohr_sdk.api.employee_verification_api import EmployeeVerificationApi
from bamboohr_sdk.api.employee_files_api import EmployeeFilesApi
from bamboohr_sdk.api.employees_api import EmployeesApi
from bamboohr_sdk.api.goals_api import GoalsApi
from bamboohr_sdk.api.hours_api import HoursApi
from bamboohr_sdk.api.last_change_information_api import LastChangeInformationApi
from bamboohr_sdk.api.locations_api import LocationsApi
from bamboohr_sdk.api.login_api import LoginApi
from bamboohr_sdk.api.onboarding_api import OnboardingApi
from bamboohr_sdk.api.photos_api import PhotosApi
from bamboohr_sdk.api.reports_api import ReportsApi
from bamboohr_sdk.api.scheduling_api import SchedulingApi
from bamboohr_sdk.api.tabular_data_api import TabularDataApi
from bamboohr_sdk.api.time_off_api import TimeOffApi
from bamboohr_sdk.api.time_tracking_api import TimeTrackingApi
from bamboohr_sdk.api.total_rewards_api import TotalRewardsApi
from bamboohr_sdk.api.training_api import TrainingApi
from bamboohr_sdk.api.webhooks_api import WebhooksApi

2,745 changes: 1,800 additions & 945 deletions bamboohr_sdk/api/account_information_api.py

Large diffs are not rendered by default.

234 changes: 234 additions & 0 deletions bamboohr_sdk/api/alert_api.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,234 @@
"""
BambooHR API

BambooHR API documentation. https://www.bamboohr.com/api/documentation/

The version of the OpenAPI document: 1.0
Generated by OpenAPI Generator (https://openapi-generator.tech)

Do not edit the class manually.
"""

from typing import Annotated, Any

from pydantic import Field, StrictFloat, StrictInt, StrictStr, validate_call

from bamboohr_sdk.api_client import ApiClient, RequestSerialized
from bamboohr_sdk.api_response import ApiResponse
from bamboohr_sdk.models.alert_template_list_response import AlertTemplateListResponse
from bamboohr_sdk.rest import RESTResponseType


class AlertApi:
"""NOTE: This class is auto generated by OpenAPI Generator
Ref: https://openapi-generator.tech

Do not edit the class manually.
"""

def __init__(self, api_client=None) -> None:
if api_client is None:
api_client = ApiClient.get_default()
self.api_client = api_client

@validate_call
def call_0f0dcb585e5883175b6557c16cf6755a(
self,
_request_timeout: None
| Annotated[StrictFloat, Field(gt=0)]
| tuple[Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]] = None,
_request_auth: dict[StrictStr, Any] | None = None,
_content_type: StrictStr | None = None,
_headers: dict[StrictStr, Any] | None = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> AlertTemplateListResponse:
"""List alert templates

Returns all available alert templates with their IDs, names, and group names. Use the returned IDs when creating or updating company alert configurations.

:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
:type _request_timeout: int, tuple(int, int), optional
:param _request_auth: set to override the auth_settings for an a single
request; this effectively ignores the
authentication in the spec for a single request.
:type _request_auth: dict, optional
:param _content_type: force content-type for the request.
:type _content_type: str, Optional
:param _headers: set to override the headers for a single
request; this effectively ignores the headers
in the spec for a single request.
:type _headers: dict, optional
:param _host_index: set to override the host_index for a single
request; this effectively ignores the host_index
in the spec for a single request.
:type _host_index: int, optional
:return: Returns the result object.
"""

_param = self._call_0f0dcb585e5883175b6557c16cf6755a_serialize(
_request_auth=_request_auth, _content_type=_content_type, _headers=_headers, _host_index=_host_index
)

_response_types_map: dict[str, str | None] = {
"200": "AlertTemplateListResponse",
"403": None,
"500": None,
}
response_data = self.api_client.call_api(*_param, _request_timeout=_request_timeout)
response_data.read()
return self.api_client.response_deserialize(
response_data=response_data,
response_types_map=_response_types_map,
).data

@validate_call
def call_0f0dcb585e5883175b6557c16cf6755a_with_http_info(
self,
_request_timeout: None
| Annotated[StrictFloat, Field(gt=0)]
| tuple[Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]] = None,
_request_auth: dict[StrictStr, Any] | None = None,
_content_type: StrictStr | None = None,
_headers: dict[StrictStr, Any] | None = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[AlertTemplateListResponse]:
"""List alert templates

Returns all available alert templates with their IDs, names, and group names. Use the returned IDs when creating or updating company alert configurations.

:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
:type _request_timeout: int, tuple(int, int), optional
:param _request_auth: set to override the auth_settings for an a single
request; this effectively ignores the
authentication in the spec for a single request.
:type _request_auth: dict, optional
:param _content_type: force content-type for the request.
:type _content_type: str, Optional
:param _headers: set to override the headers for a single
request; this effectively ignores the headers
in the spec for a single request.
:type _headers: dict, optional
:param _host_index: set to override the host_index for a single
request; this effectively ignores the host_index
in the spec for a single request.
:type _host_index: int, optional
:return: Returns the result object.
"""

_param = self._call_0f0dcb585e5883175b6557c16cf6755a_serialize(
_request_auth=_request_auth, _content_type=_content_type, _headers=_headers, _host_index=_host_index
)

_response_types_map: dict[str, str | None] = {
"200": "AlertTemplateListResponse",
"403": None,
"500": None,
}
response_data = self.api_client.call_api(*_param, _request_timeout=_request_timeout)
response_data.read()
return self.api_client.response_deserialize(
response_data=response_data,
response_types_map=_response_types_map,
)

@validate_call
def call_0f0dcb585e5883175b6557c16cf6755a_without_preload_content(
self,
_request_timeout: None
| Annotated[StrictFloat, Field(gt=0)]
| tuple[Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]] = None,
_request_auth: dict[StrictStr, Any] | None = None,
_content_type: StrictStr | None = None,
_headers: dict[StrictStr, Any] | None = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""List alert templates

Returns all available alert templates with their IDs, names, and group names. Use the returned IDs when creating or updating company alert configurations.

:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
:type _request_timeout: int, tuple(int, int), optional
:param _request_auth: set to override the auth_settings for an a single
request; this effectively ignores the
authentication in the spec for a single request.
:type _request_auth: dict, optional
:param _content_type: force content-type for the request.
:type _content_type: str, Optional
:param _headers: set to override the headers for a single
request; this effectively ignores the headers
in the spec for a single request.
:type _headers: dict, optional
:param _host_index: set to override the host_index for a single
request; this effectively ignores the host_index
in the spec for a single request.
:type _host_index: int, optional
:return: Returns the result object.
"""

_param = self._call_0f0dcb585e5883175b6557c16cf6755a_serialize(
_request_auth=_request_auth, _content_type=_content_type, _headers=_headers, _host_index=_host_index
)

_response_types_map: dict[str, str | None] = {
"200": "AlertTemplateListResponse",
"403": None,
"500": None,
}
response_data = self.api_client.call_api(*_param, _request_timeout=_request_timeout)
return response_data.response

def _call_0f0dcb585e5883175b6557c16cf6755a_serialize(
self,
_request_auth,
_content_type,
_headers,
_host_index,
) -> RequestSerialized:

_host = None

_collection_formats: dict[str, str] = {}

_path_params: dict[str, str] = {}
_query_params: list[tuple[str, str]] = []
_header_params: dict[str, str | None] = _headers or {}
_form_params: list[tuple[str, str]] = []
_files: dict[str, str | bytes | list[str] | list[bytes] | list[tuple[str, bytes]]] = {}
_body_params: bytes | None = None

# process the path parameters
# process the query parameters
# process the header parameters
# process the form parameters
# process the body parameter

# set the HTTP header `Accept`
if "Accept" not in _header_params:
_header_params["Accept"] = self.api_client.select_header_accept(["application/json"])

# authentication setting
_auth_settings: list[str] = ["oauth"]

return self.api_client.param_serialize(
method="GET",
resource_path="/api/v1/alerts",
path_params=_path_params,
query_params=_query_params,
header_params=_header_params,
body=_body_params,
post_params=_form_params,
files=_files,
auth_settings=_auth_settings,
collection_formats=_collection_formats,
_host=_host,
_request_auth=_request_auth,
)
Loading