merge_hris_client 1.0.2 → 2.0.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +59 -19
- data/docs/AccountDetails.md +30 -0
- data/docs/AccountDetailsAndActions.md +32 -0
- data/docs/AccountDetailsAndActionsIntegration.md +32 -0
- data/docs/AccountDetailsAndActionsStatusEnum.md +15 -0
- data/docs/AccountDetailsApi.md +76 -0
- data/docs/AccountIntegration.md +4 -4
- data/docs/AccountTokenApi.md +2 -2
- data/docs/AccountTypeEnum.md +15 -0
- data/docs/AvailableActionsApi.md +2 -2
- data/docs/BankInfo.md +34 -0
- data/docs/BankInfoApi.md +189 -0
- data/docs/Benefit.md +2 -2
- data/docs/BenefitsApi.md +6 -82
- data/docs/CategoriesEnum.md +15 -0
- data/docs/{StateEnum.md → CategoryEnum.md} +2 -2
- data/docs/CompaniesApi.md +6 -4
- data/docs/DataPassthroughRequest.md +7 -3
- data/docs/DebugModeLog.md +22 -0
- data/docs/DebugModelLogSummary.md +22 -0
- data/docs/Deduction.md +2 -2
- data/docs/DeductionsApi.md +179 -0
- data/docs/DeleteAccountApi.md +3 -2
- data/docs/Earning.md +3 -3
- data/docs/EarningTypeEnum.md +15 -0
- data/docs/Employee.md +20 -14
- data/docs/EmployeeEndpointRequest.md +18 -0
- data/docs/EmployeePayrollRun.md +5 -5
- data/docs/EmployeePayrollRunsApi.md +17 -7
- data/docs/EmployeeRequest.md +21 -13
- data/docs/EmployeeResponse.md +24 -0
- data/docs/EmployeesApi.md +101 -17
- data/docs/Employment.md +3 -1
- data/docs/EmploymentsApi.md +12 -82
- data/docs/EncodingEnum.md +15 -0
- data/docs/EndUserDetailsRequest.md +4 -2
- data/docs/ErrorValidationProblem.md +24 -0
- data/docs/ForceResyncApi.md +79 -0
- data/docs/GenerateKeyApi.md +2 -2
- data/docs/Group.md +28 -0
- data/docs/GroupTypeEnum.md +15 -0
- data/docs/GroupsApi.md +177 -0
- data/docs/IgnoreCommonModel.md +20 -0
- data/docs/IgnoreCommonModelRequest.md +20 -0
- data/docs/IssuesApi.md +16 -14
- data/docs/LinkTokenApi.md +3 -3
- data/docs/LinkedAccountsApi.md +103 -0
- data/docs/Location.md +4 -0
- data/docs/LocationTypeEnum.md +15 -0
- data/docs/LocationsApi.md +6 -4
- data/docs/MultipartFormFieldRequest.md +26 -0
- data/docs/PaginatedAccountDetailsAndActionsList.md +22 -0
- data/docs/PaginatedBankInfoList.md +22 -0
- data/docs/PaginatedDeductionList.md +22 -0
- data/docs/PaginatedGroupList.md +22 -0
- data/docs/PaginatedIssueList.md +2 -2
- data/docs/PaginatedPayGroupList.md +22 -0
- data/docs/PaginatedSyncStatusList.md +2 -2
- data/docs/PassthroughApi.md +2 -2
- data/docs/PayGroup.md +24 -0
- data/docs/PayGroupsApi.md +177 -0
- data/docs/PayrollRun.md +3 -3
- data/docs/PayrollRunsApi.md +17 -5
- data/docs/PolicyTypeEnum.md +15 -0
- data/docs/{NullEnum.md → ReasonEnum.md} +2 -2
- data/docs/RegenerateKeyApi.md +2 -2
- data/docs/RequestFormatEnum.md +15 -0
- data/docs/SyncStatusApi.md +3 -75
- data/docs/Tax.md +2 -2
- data/docs/Team.md +1 -1
- data/docs/TeamsApi.md +12 -6
- data/docs/TimeOff.md +5 -5
- data/docs/TimeOffApi.md +92 -6
- data/docs/TimeOffBalance.md +5 -3
- data/docs/{TimeOffBalanceApi.md → TimeOffBalancesApi.md} +26 -22
- data/docs/TimeOffEndpointRequest.md +18 -0
- data/docs/TimeOffRequest.md +36 -0
- data/docs/TimeOffResponse.md +24 -0
- data/docs/ValidationProblemSource.md +18 -0
- data/docs/WarningValidationProblem.md +24 -0
- data/lib/merge_hris_client/api/account_details_api.rb +77 -0
- data/lib/merge_hris_client/api/bank_info_api.rb +217 -0
- data/lib/merge_hris_client/api/benefits_api.rb +3 -69
- data/lib/merge_hris_client/api/companies_api.rb +3 -0
- data/lib/merge_hris_client/api/deductions_api.rb +185 -0
- data/lib/merge_hris_client/api/employee_payroll_runs_api.rb +17 -2
- data/lib/merge_hris_client/api/employees_api.rb +103 -15
- data/lib/merge_hris_client/api/employments_api.rb +24 -69
- data/lib/merge_hris_client/api/force_resync_api.rb +84 -0
- data/lib/merge_hris_client/api/groups_api.rb +182 -0
- data/lib/merge_hris_client/api/issues_api.rb +10 -10
- data/lib/merge_hris_client/api/linked_accounts_api.rb +117 -0
- data/lib/merge_hris_client/api/locations_api.rb +3 -0
- data/lib/merge_hris_client/api/pay_groups_api.rb +182 -0
- data/lib/merge_hris_client/api/payroll_runs_api.rb +22 -0
- data/lib/merge_hris_client/api/sync_status_api.rb +4 -66
- data/lib/merge_hris_client/api/teams_api.rb +17 -0
- data/lib/merge_hris_client/api/time_off_api.rb +95 -2
- data/lib/merge_hris_client/api/time_off_balances_api.rb +206 -0
- data/lib/merge_hris_client/configuration.rb +6 -4
- data/lib/merge_hris_client/models/account_details.rb +273 -0
- data/lib/merge_hris_client/models/account_details_and_actions.rb +302 -0
- data/lib/merge_hris_client/models/account_details_and_actions_integration.rb +310 -0
- data/lib/merge_hris_client/models/account_details_and_actions_status_enum.rb +37 -0
- data/lib/merge_hris_client/models/account_integration.rb +6 -28
- data/lib/merge_hris_client/models/account_token.rb +1 -1
- data/lib/merge_hris_client/models/account_type_enum.rb +36 -0
- data/lib/merge_hris_client/models/available_actions.rb +1 -1
- data/lib/merge_hris_client/models/bank_info.rb +322 -0
- data/lib/merge_hris_client/models/benefit.rb +2 -3
- data/lib/merge_hris_client/models/categories_enum.rb +37 -0
- data/lib/merge_hris_client/models/category_enum.rb +37 -0
- data/lib/merge_hris_client/models/company.rb +1 -1
- data/lib/merge_hris_client/models/country_enum.rb +1 -0
- data/lib/merge_hris_client/models/data_passthrough_request.rb +79 -9
- data/lib/merge_hris_client/models/debug_mode_log.rb +251 -0
- data/lib/merge_hris_client/models/debug_model_log_summary.rb +251 -0
- data/lib/merge_hris_client/models/deduction.rb +1 -2
- data/lib/merge_hris_client/models/earning.rb +4 -8
- data/lib/merge_hris_client/models/earning_type_enum.rb +38 -0
- data/lib/merge_hris_client/models/employee.rb +43 -14
- data/lib/merge_hris_client/models/employee_endpoint_request.rb +223 -0
- data/lib/merge_hris_client/models/employee_payroll_run.rb +1 -3
- data/lib/merge_hris_client/models/employee_request.rb +55 -14
- data/lib/merge_hris_client/models/employee_response.rb +266 -0
- data/lib/merge_hris_client/models/employment.rb +12 -2
- data/lib/merge_hris_client/models/employment_status_enum.rb +1 -1
- data/lib/merge_hris_client/models/employment_type_enum.rb +1 -1
- data/lib/merge_hris_client/models/encoding_enum.rb +36 -0
- data/lib/merge_hris_client/models/end_user_details_request.rb +113 -28
- data/lib/merge_hris_client/models/error_validation_problem.rb +260 -0
- data/lib/merge_hris_client/models/ethnicity_enum.rb +1 -1
- data/lib/merge_hris_client/models/flsa_status_enum.rb +1 -1
- data/lib/merge_hris_client/models/gender_enum.rb +1 -1
- data/lib/merge_hris_client/models/generate_remote_key_request.rb +20 -1
- data/lib/merge_hris_client/models/{benefit_request.rb → group.rb} +48 -49
- data/lib/merge_hris_client/models/group_type_enum.rb +38 -0
- data/lib/merge_hris_client/models/ignore_common_model.rb +247 -0
- data/lib/merge_hris_client/models/ignore_common_model_request.rb +256 -0
- data/lib/merge_hris_client/models/issue.rb +1 -1
- data/lib/merge_hris_client/models/issue_status_enum.rb +1 -1
- data/lib/merge_hris_client/models/link_token.rb +1 -1
- data/lib/merge_hris_client/models/location.rb +24 -2
- data/lib/merge_hris_client/models/location_type_enum.rb +36 -0
- data/lib/merge_hris_client/models/marital_status_enum.rb +2 -2
- data/lib/merge_hris_client/models/method_enum.rb +1 -1
- data/lib/merge_hris_client/models/model_operation.rb +1 -1
- data/lib/merge_hris_client/models/multipart_form_field_request.rb +341 -0
- data/lib/merge_hris_client/models/paginated_account_details_and_actions_list.rb +240 -0
- data/lib/merge_hris_client/models/paginated_bank_info_list.rb +240 -0
- data/lib/merge_hris_client/models/paginated_benefit_list.rb +1 -1
- data/lib/merge_hris_client/models/paginated_company_list.rb +1 -1
- data/lib/merge_hris_client/models/paginated_deduction_list.rb +240 -0
- data/lib/merge_hris_client/models/paginated_employee_list.rb +1 -1
- data/lib/merge_hris_client/models/paginated_employee_payroll_run_list.rb +1 -1
- data/lib/merge_hris_client/models/paginated_employment_list.rb +1 -1
- data/lib/merge_hris_client/models/paginated_group_list.rb +240 -0
- data/lib/merge_hris_client/models/paginated_issue_list.rb +1 -1
- data/lib/merge_hris_client/models/paginated_location_list.rb +1 -1
- data/lib/merge_hris_client/models/paginated_pay_group_list.rb +240 -0
- data/lib/merge_hris_client/models/paginated_payroll_run_list.rb +1 -1
- data/lib/merge_hris_client/models/paginated_sync_status_list.rb +1 -1
- data/lib/merge_hris_client/models/paginated_team_list.rb +1 -1
- data/lib/merge_hris_client/models/paginated_time_off_balance_list.rb +1 -1
- data/lib/merge_hris_client/models/paginated_time_off_list.rb +1 -1
- data/lib/merge_hris_client/models/pay_currency_enum.rb +1 -1
- data/lib/merge_hris_client/models/pay_frequency_enum.rb +1 -2
- data/lib/merge_hris_client/models/pay_group.rb +253 -0
- data/lib/merge_hris_client/models/pay_period_enum.rb +1 -1
- data/lib/merge_hris_client/models/payroll_run.rb +1 -1
- data/lib/merge_hris_client/models/policy_type_enum.rb +40 -0
- data/lib/merge_hris_client/models/reason_enum.rb +37 -0
- data/lib/merge_hris_client/models/remote_data.rb +1 -1
- data/lib/merge_hris_client/models/remote_data_request.rb +20 -1
- data/lib/merge_hris_client/models/remote_key.rb +1 -1
- data/lib/merge_hris_client/models/remote_key_for_regeneration_request.rb +20 -1
- data/lib/merge_hris_client/models/remote_response.rb +1 -1
- data/lib/merge_hris_client/models/request_format_enum.rb +37 -0
- data/lib/merge_hris_client/models/request_type_enum.rb +3 -1
- data/lib/merge_hris_client/models/run_state_enum.rb +1 -1
- data/lib/merge_hris_client/models/run_type_enum.rb +1 -11
- data/lib/merge_hris_client/models/sync_status.rb +1 -1
- data/lib/merge_hris_client/models/sync_status_status_enum.rb +3 -2
- data/lib/merge_hris_client/models/tax.rb +3 -7
- data/lib/merge_hris_client/models/team.rb +1 -2
- data/lib/merge_hris_client/models/time_off.rb +1 -3
- data/lib/merge_hris_client/models/time_off_balance.rb +15 -5
- data/lib/merge_hris_client/models/time_off_endpoint_request.rb +223 -0
- data/lib/merge_hris_client/models/{employment_request.rb → time_off_request.rb} +79 -70
- data/lib/merge_hris_client/models/time_off_response.rb +266 -0
- data/lib/merge_hris_client/models/time_off_status_enum.rb +1 -1
- data/lib/merge_hris_client/models/units_enum.rb +1 -1
- data/lib/merge_hris_client/models/validation_problem_source.rb +223 -0
- data/lib/merge_hris_client/models/warning_validation_problem.rb +260 -0
- data/lib/merge_hris_client/version.rb +1 -1
- data/lib/merge_hris_client.rb +43 -5
- data/pull_request_template.md +3 -1
- data/spec/api/account_details_api_spec.rb +45 -0
- data/spec/api/account_token_api_spec.rb +1 -1
- data/spec/api/available_actions_api_spec.rb +1 -1
- data/spec/api/bank_info_api_spec.rb +74 -0
- data/spec/api/benefits_api_spec.rb +4 -1
- data/spec/api/companies_api_spec.rb +4 -1
- data/spec/api/deductions_api_spec.rb +69 -0
- data/spec/api/employee_payroll_runs_api_spec.rb +9 -2
- data/spec/api/employees_api_spec.rb +35 -1
- data/spec/api/employments_api_spec.rb +7 -1
- data/spec/api/force_resync_api_spec.rb +46 -0
- data/spec/api/groups_api_spec.rb +68 -0
- data/spec/api/issues_api_spec.rb +5 -5
- data/spec/api/link_token_api_spec.rb +2 -2
- data/spec/api/linked_accounts_api_spec.rb +57 -0
- data/spec/api/locations_api_spec.rb +4 -1
- data/spec/api/passthrough_api_spec.rb +2 -3
- data/spec/api/pay_groups_api_spec.rb +68 -0
- data/spec/api/payroll_runs_api_spec.rb +9 -1
- data/spec/api/regenerate_key_api_spec.rb +2 -2
- data/spec/api/sync_status_api_spec.rb +2 -13
- data/spec/api/teams_api_spec.rb +7 -1
- data/spec/api/time_off_api_spec.rb +21 -2
- data/spec/api/{time_off_balance_api_spec.rb → time_off_balances_api_spec.rb} +13 -11
- data/spec/models/account_details_and_actions_integration_spec.rb +76 -0
- data/spec/models/account_details_and_actions_spec.rb +76 -0
- data/spec/models/account_details_and_actions_status_enum_spec.rb +28 -0
- data/spec/models/account_details_spec.rb +70 -0
- data/spec/models/account_integration_spec.rb +7 -1
- data/spec/models/account_token_spec.rb +7 -1
- data/spec/models/account_type_enum_spec.rb +28 -0
- data/spec/models/available_actions_spec.rb +13 -1
- data/spec/models/{employment_request_spec.rb → bank_info_spec.rb} +15 -15
- data/spec/models/benefit_plan_type_enum_spec.rb +1 -1
- data/spec/models/benefit_spec.rb +7 -1
- data/spec/models/categories_enum_spec.rb +28 -0
- data/spec/models/category_enum_spec.rb +28 -0
- data/spec/models/company_spec.rb +7 -1
- data/spec/models/country_enum_spec.rb +1 -1
- data/spec/models/data_passthrough_request_spec.rb +13 -1
- data/spec/models/debug_mode_log_spec.rb +46 -0
- data/spec/models/debug_model_log_summary_spec.rb +46 -0
- data/spec/models/deduction_spec.rb +7 -1
- data/spec/models/earning_spec.rb +7 -1
- data/spec/models/earning_type_enum_spec.rb +28 -0
- data/spec/models/{remote_key_for_regeneration_spec.rb → employee_endpoint_request_spec.rb} +8 -8
- data/spec/models/employee_payroll_run_spec.rb +7 -1
- data/spec/models/employee_request_spec.rb +30 -0
- data/spec/models/{end_user_details_spec.rb → employee_response_spec.rb} +11 -15
- data/spec/models/employee_spec.rb +37 -1
- data/spec/models/employment_spec.rb +13 -1
- data/spec/models/employment_status_enum_spec.rb +1 -1
- data/spec/models/employment_type_enum_spec.rb +1 -1
- data/spec/models/encoding_enum_spec.rb +28 -0
- data/spec/models/end_user_details_request_spec.rb +13 -5
- data/spec/models/error_validation_problem_spec.rb +52 -0
- data/spec/models/ethnicity_enum_spec.rb +1 -1
- data/spec/models/flsa_status_enum_spec.rb +1 -1
- data/spec/models/gender_enum_spec.rb +1 -1
- data/spec/models/{benefit_request_spec.rb → group_spec.rb} +12 -12
- data/spec/models/group_type_enum_spec.rb +28 -0
- data/spec/models/ignore_common_model_request_spec.rb +40 -0
- data/spec/models/ignore_common_model_spec.rb +40 -0
- data/spec/models/link_token_spec.rb +1 -1
- data/spec/models/location_spec.rb +19 -1
- data/spec/models/location_type_enum_spec.rb +28 -0
- data/spec/models/marital_status_enum_spec.rb +1 -1
- data/spec/models/method_enum_spec.rb +1 -1
- data/spec/models/model_operation_spec.rb +13 -1
- data/spec/models/multipart_form_field_request_spec.rb +58 -0
- data/spec/models/paginated_account_details_and_actions_list_spec.rb +46 -0
- data/spec/models/paginated_bank_info_list_spec.rb +46 -0
- data/spec/models/paginated_benefit_list_spec.rb +1 -1
- data/spec/models/paginated_company_list_spec.rb +1 -1
- data/spec/models/paginated_deduction_list_spec.rb +46 -0
- data/spec/models/paginated_employee_list_spec.rb +1 -1
- data/spec/models/paginated_employee_payroll_run_list_spec.rb +1 -1
- data/spec/models/paginated_employment_list_spec.rb +1 -1
- data/spec/models/paginated_group_list_spec.rb +46 -0
- data/spec/models/paginated_location_list_spec.rb +1 -1
- data/spec/models/paginated_pay_group_list_spec.rb +46 -0
- data/spec/models/paginated_payroll_run_list_spec.rb +1 -1
- data/spec/models/paginated_team_list_spec.rb +1 -1
- data/spec/models/paginated_time_off_list_spec.rb +1 -1
- data/spec/models/pay_currency_enum_spec.rb +1 -1
- data/spec/models/pay_frequency_enum_spec.rb +1 -1
- data/spec/models/{data_passthrough_spec.rb → pay_group_spec.rb} +11 -11
- data/spec/models/pay_period_enum_spec.rb +1 -1
- data/spec/models/payroll_run_spec.rb +7 -1
- data/spec/models/policy_type_enum_spec.rb +28 -0
- data/spec/models/{state_enum_spec.rb → reason_enum_spec.rb} +7 -7
- data/spec/models/remote_data_spec.rb +1 -1
- data/spec/models/remote_key_for_regeneration_request_spec.rb +1 -1
- data/spec/models/remote_key_spec.rb +1 -1
- data/spec/models/remote_response_spec.rb +1 -1
- data/spec/models/request_format_enum_spec.rb +28 -0
- data/spec/models/request_type_enum_spec.rb +1 -1
- data/spec/models/run_state_enum_spec.rb +1 -1
- data/spec/models/run_type_enum_spec.rb +1 -1
- data/spec/models/tax_spec.rb +7 -1
- data/spec/models/team_spec.rb +13 -1
- data/spec/models/time_off_balance_spec.rb +6 -0
- data/spec/models/time_off_endpoint_request_spec.rb +34 -0
- data/spec/models/time_off_request_spec.rb +88 -0
- data/spec/models/time_off_response_spec.rb +52 -0
- data/spec/models/time_off_spec.rb +19 -1
- data/spec/models/time_off_status_enum_spec.rb +1 -1
- data/spec/models/type_enum_spec.rb +1 -1
- data/spec/models/units_enum_spec.rb +1 -1
- data/spec/models/validation_problem_source_spec.rb +34 -0
- data/spec/models/warning_validation_problem_spec.rb +52 -0
- data/test_ruby.rb +11 -14
- metadata +175 -29
- data/docs/BenefitRequest.md +0 -28
- data/docs/DataPassthrough.md +0 -24
- data/docs/EmploymentRequest.md +0 -34
- data/docs/EndUserDetails.md +0 -24
- data/docs/RemoteKeyForRegeneration.md +0 -18
- data/merge_hris_client-1.0.0.gem +0 -0
- data/merge_hris_client-1.0.1.gem +0 -0
@@ -0,0 +1,256 @@
|
|
1
|
+
=begin
|
2
|
+
#Merge HRIS API
|
3
|
+
|
4
|
+
#The unified API for building rich integrations with multiple HR Information System platforms.
|
5
|
+
|
6
|
+
The version of the OpenAPI document: 1.0
|
7
|
+
Contact: hello@merge.dev
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
OpenAPI Generator version: 5.1.1
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require 'date'
|
14
|
+
require 'time'
|
15
|
+
|
16
|
+
module MergeHRISClient
|
17
|
+
class IgnoreCommonModelRequest
|
18
|
+
attr_accessor :reason
|
19
|
+
|
20
|
+
attr_accessor :message
|
21
|
+
|
22
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
23
|
+
def self.attribute_map
|
24
|
+
{
|
25
|
+
:'reason' => :'reason',
|
26
|
+
:'message' => :'message'
|
27
|
+
}
|
28
|
+
end
|
29
|
+
|
30
|
+
# Returns all the JSON keys this model knows about
|
31
|
+
def self.acceptable_attributes
|
32
|
+
attribute_map.values
|
33
|
+
end
|
34
|
+
|
35
|
+
# Attribute type mapping.
|
36
|
+
def self.openapi_types
|
37
|
+
{
|
38
|
+
:'reason' => :'ReasonEnum',
|
39
|
+
:'message' => :'String'
|
40
|
+
}
|
41
|
+
end
|
42
|
+
|
43
|
+
# List of attributes with nullable: true
|
44
|
+
def self.openapi_nullable
|
45
|
+
Set.new([
|
46
|
+
])
|
47
|
+
end
|
48
|
+
|
49
|
+
# Initializes the object
|
50
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
51
|
+
def initialize(attributes = {})
|
52
|
+
if (!attributes.is_a?(Hash))
|
53
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `MergeHRISClient::IgnoreCommonModelRequest` initialize method"
|
54
|
+
end
|
55
|
+
|
56
|
+
# check to see if the attribute exists and convert string to symbol for hash key
|
57
|
+
attributes = attributes.each_with_object({}) { |(k, v), h|
|
58
|
+
if (!self.class.attribute_map.key?(k.to_sym))
|
59
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `MergeHRISClient::IgnoreCommonModelRequest`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
60
|
+
end
|
61
|
+
h[k.to_sym] = v
|
62
|
+
}
|
63
|
+
|
64
|
+
if attributes.key?(:'reason')
|
65
|
+
self.reason = attributes[:'reason']
|
66
|
+
end
|
67
|
+
|
68
|
+
if attributes.key?(:'message')
|
69
|
+
self.message = attributes[:'message']
|
70
|
+
end
|
71
|
+
end
|
72
|
+
|
73
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
74
|
+
# @return Array for valid properties with the reasons
|
75
|
+
def list_invalid_properties
|
76
|
+
invalid_properties = Array.new
|
77
|
+
if @reason.nil?
|
78
|
+
invalid_properties.push('invalid value for "reason", reason cannot be nil.')
|
79
|
+
end
|
80
|
+
|
81
|
+
if !@message.nil? && @message.to_s.length > 256
|
82
|
+
invalid_properties.push('invalid value for "message", the character length must be smaller than or equal to 256.')
|
83
|
+
end
|
84
|
+
|
85
|
+
if !@message.nil? && @message.to_s.length < 1
|
86
|
+
invalid_properties.push('invalid value for "message", the character length must be great than or equal to 1.')
|
87
|
+
end
|
88
|
+
|
89
|
+
invalid_properties
|
90
|
+
end
|
91
|
+
|
92
|
+
# Check to see if the all the properties in the model are valid
|
93
|
+
# @return true if the model is valid
|
94
|
+
def valid?
|
95
|
+
return false if @reason.nil?
|
96
|
+
return false if !@message.nil? && @message.to_s.length > 256
|
97
|
+
return false if !@message.nil? && @message.to_s.length < 1
|
98
|
+
true
|
99
|
+
end
|
100
|
+
|
101
|
+
# Custom attribute writer method with validation
|
102
|
+
# @param [Object] message Value to be assigned
|
103
|
+
def message=(message)
|
104
|
+
if !message.nil? && message.to_s.length > 256
|
105
|
+
fail ArgumentError, 'invalid value for "message", the character length must be smaller than or equal to 256.'
|
106
|
+
end
|
107
|
+
|
108
|
+
if !message.nil? && message.to_s.length < 1
|
109
|
+
fail ArgumentError, 'invalid value for "message", the character length must be great than or equal to 1.'
|
110
|
+
end
|
111
|
+
|
112
|
+
@message = message
|
113
|
+
end
|
114
|
+
|
115
|
+
# Checks equality by comparing each attribute.
|
116
|
+
# @param [Object] Object to be compared
|
117
|
+
def ==(o)
|
118
|
+
return true if self.equal?(o)
|
119
|
+
self.class == o.class &&
|
120
|
+
reason == o.reason &&
|
121
|
+
message == o.message
|
122
|
+
end
|
123
|
+
|
124
|
+
# @see the `==` method
|
125
|
+
# @param [Object] Object to be compared
|
126
|
+
def eql?(o)
|
127
|
+
self == o
|
128
|
+
end
|
129
|
+
|
130
|
+
# Calculates hash code according to all attributes.
|
131
|
+
# @return [Integer] Hash code
|
132
|
+
def hash
|
133
|
+
[reason, message].hash
|
134
|
+
end
|
135
|
+
|
136
|
+
# Builds the object from hash
|
137
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
138
|
+
# @return [Object] Returns the model itself
|
139
|
+
def self.build_from_hash(attributes)
|
140
|
+
new.build_from_hash(attributes)
|
141
|
+
end
|
142
|
+
|
143
|
+
# Builds the object from hash
|
144
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
145
|
+
# @return [Object] Returns the model itself
|
146
|
+
def build_from_hash(attributes)
|
147
|
+
return nil unless attributes.is_a?(Hash)
|
148
|
+
self.class.openapi_types.each_pair do |key, type|
|
149
|
+
if attributes[self.class.attribute_map[key]].nil? && self.class.openapi_nullable.include?(key)
|
150
|
+
self.send("#{key}=", nil)
|
151
|
+
elsif type =~ /\AArray<(.*)>/i
|
152
|
+
# check to ensure the input is an array given that the attribute
|
153
|
+
# is documented as an array but the input is not
|
154
|
+
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
155
|
+
self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
|
156
|
+
end
|
157
|
+
elsif !attributes[self.class.attribute_map[key]].nil?
|
158
|
+
self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
159
|
+
end
|
160
|
+
end
|
161
|
+
|
162
|
+
self
|
163
|
+
end
|
164
|
+
|
165
|
+
# Deserializes the data based on type
|
166
|
+
# @param string type Data type
|
167
|
+
# @param string value Value to be deserialized
|
168
|
+
# @return [Object] Deserialized data
|
169
|
+
def _deserialize(type, value)
|
170
|
+
case type.to_sym
|
171
|
+
when :Time
|
172
|
+
Time.parse(value)
|
173
|
+
when :Date
|
174
|
+
Date.parse(value)
|
175
|
+
when :String
|
176
|
+
value
|
177
|
+
when :Integer
|
178
|
+
value.to_i
|
179
|
+
when :Float
|
180
|
+
value.to_f
|
181
|
+
when :Boolean
|
182
|
+
if value.to_s =~ /\A(true|t|yes|y|1)\z/i
|
183
|
+
true
|
184
|
+
else
|
185
|
+
false
|
186
|
+
end
|
187
|
+
when :Object
|
188
|
+
# generic object (usually a Hash), return directly
|
189
|
+
value
|
190
|
+
when /\AArray<(?<inner_type>.+)>\z/
|
191
|
+
inner_type = Regexp.last_match[:inner_type]
|
192
|
+
value.map { |v| _deserialize(inner_type, v) }
|
193
|
+
when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
|
194
|
+
k_type = Regexp.last_match[:k_type]
|
195
|
+
v_type = Regexp.last_match[:v_type]
|
196
|
+
{}.tap do |hash|
|
197
|
+
value.each do |k, v|
|
198
|
+
hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
|
199
|
+
end
|
200
|
+
end
|
201
|
+
else # model
|
202
|
+
# models (e.g. Pet) or oneOf
|
203
|
+
klass = MergeHRISClient.const_get(type)
|
204
|
+
klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
|
205
|
+
end
|
206
|
+
end
|
207
|
+
|
208
|
+
# Returns the string representation of the object
|
209
|
+
# @return [String] String presentation of the object
|
210
|
+
def to_s
|
211
|
+
to_hash.to_s
|
212
|
+
end
|
213
|
+
|
214
|
+
# to_body is an alias to to_hash (backward compatibility)
|
215
|
+
# @return [Hash] Returns the object in the form of hash
|
216
|
+
def to_body
|
217
|
+
to_hash
|
218
|
+
end
|
219
|
+
|
220
|
+
# Returns the object in the form of hash
|
221
|
+
# @return [Hash] Returns the object in the form of hash
|
222
|
+
def to_hash
|
223
|
+
hash = {}
|
224
|
+
self.class.attribute_map.each_pair do |attr, param|
|
225
|
+
value = self.send(attr)
|
226
|
+
if value.nil?
|
227
|
+
is_nullable = self.class.openapi_nullable.include?(attr)
|
228
|
+
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
229
|
+
end
|
230
|
+
|
231
|
+
hash[param] = _to_hash(value)
|
232
|
+
end
|
233
|
+
hash
|
234
|
+
end
|
235
|
+
|
236
|
+
# Outputs non-array value in the form of hash
|
237
|
+
# For object, use to_hash. Otherwise, just return the value
|
238
|
+
# @param [Object] value Any valid value
|
239
|
+
# @return [Hash] Returns the value in the form of hash
|
240
|
+
def _to_hash(value)
|
241
|
+
if value.is_a?(Array)
|
242
|
+
value.compact.map { |v| _to_hash(v) }
|
243
|
+
elsif value.is_a?(Hash)
|
244
|
+
{}.tap do |hash|
|
245
|
+
value.each { |k, v| hash[k] = _to_hash(v) }
|
246
|
+
end
|
247
|
+
elsif value.respond_to? :to_hash
|
248
|
+
value.to_hash
|
249
|
+
else
|
250
|
+
value
|
251
|
+
end
|
252
|
+
end
|
253
|
+
|
254
|
+
end
|
255
|
+
|
256
|
+
end
|
@@ -29,8 +29,8 @@ module MergeHRISClient
|
|
29
29
|
# @param [String] The enum value in the form of the string
|
30
30
|
# @return [String] The enum value
|
31
31
|
def build_from_hash(value)
|
32
|
-
constantValues = IssueStatusEnum.constants.select { |c| IssueStatusEnum::const_get(c) == value }
|
33
32
|
value
|
34
33
|
end
|
35
34
|
end
|
35
|
+
|
36
36
|
end
|
@@ -21,6 +21,9 @@ module MergeHRISClient
|
|
21
21
|
# The third-party API ID of the matching object.
|
22
22
|
attr_accessor :remote_id
|
23
23
|
|
24
|
+
# The location's name.
|
25
|
+
attr_accessor :name
|
26
|
+
|
24
27
|
# The location's phone number.
|
25
28
|
attr_accessor :phone_number
|
26
29
|
|
@@ -42,6 +45,9 @@ module MergeHRISClient
|
|
42
45
|
# The location's country.
|
43
46
|
attr_accessor :country
|
44
47
|
|
48
|
+
# The location's type. Can be either WORK or HOME
|
49
|
+
attr_accessor :location_type
|
50
|
+
|
45
51
|
attr_accessor :remote_data
|
46
52
|
|
47
53
|
# Attribute mapping from ruby-style variable name to JSON key.
|
@@ -49,6 +55,7 @@ module MergeHRISClient
|
|
49
55
|
{
|
50
56
|
:'id' => :'id',
|
51
57
|
:'remote_id' => :'remote_id',
|
58
|
+
:'name' => :'name',
|
52
59
|
:'phone_number' => :'phone_number',
|
53
60
|
:'street_1' => :'street_1',
|
54
61
|
:'street_2' => :'street_2',
|
@@ -56,6 +63,7 @@ module MergeHRISClient
|
|
56
63
|
:'state' => :'state',
|
57
64
|
:'zip_code' => :'zip_code',
|
58
65
|
:'country' => :'country',
|
66
|
+
:'location_type' => :'location_type',
|
59
67
|
:'remote_data' => :'remote_data'
|
60
68
|
}
|
61
69
|
end
|
@@ -70,6 +78,7 @@ module MergeHRISClient
|
|
70
78
|
{
|
71
79
|
:'id' => :'String',
|
72
80
|
:'remote_id' => :'String',
|
81
|
+
:'name' => :'String',
|
73
82
|
:'phone_number' => :'String',
|
74
83
|
:'street_1' => :'String',
|
75
84
|
:'street_2' => :'String',
|
@@ -77,6 +86,7 @@ module MergeHRISClient
|
|
77
86
|
:'state' => :'String',
|
78
87
|
:'zip_code' => :'String',
|
79
88
|
:'country' => :'CountryEnum',
|
89
|
+
:'location_type' => :'LocationTypeEnum',
|
80
90
|
:'remote_data' => :'Array<RemoteData>'
|
81
91
|
}
|
82
92
|
end
|
@@ -85,6 +95,7 @@ module MergeHRISClient
|
|
85
95
|
def self.openapi_nullable
|
86
96
|
Set.new([
|
87
97
|
:'remote_id',
|
98
|
+
:'name',
|
88
99
|
:'phone_number',
|
89
100
|
:'street_1',
|
90
101
|
:'street_2',
|
@@ -92,6 +103,7 @@ module MergeHRISClient
|
|
92
103
|
:'state',
|
93
104
|
:'zip_code',
|
94
105
|
:'country',
|
106
|
+
:'location_type',
|
95
107
|
:'remote_data'
|
96
108
|
])
|
97
109
|
end
|
@@ -119,6 +131,10 @@ module MergeHRISClient
|
|
119
131
|
self.remote_id = attributes[:'remote_id']
|
120
132
|
end
|
121
133
|
|
134
|
+
if attributes.key?(:'name')
|
135
|
+
self.name = attributes[:'name']
|
136
|
+
end
|
137
|
+
|
122
138
|
if attributes.key?(:'phone_number')
|
123
139
|
self.phone_number = attributes[:'phone_number']
|
124
140
|
end
|
@@ -147,6 +163,10 @@ module MergeHRISClient
|
|
147
163
|
self.country = attributes[:'country']
|
148
164
|
end
|
149
165
|
|
166
|
+
if attributes.key?(:'location_type')
|
167
|
+
self.location_type = attributes[:'location_type']
|
168
|
+
end
|
169
|
+
|
150
170
|
if attributes.key?(:'remote_data')
|
151
171
|
if (value = attributes[:'remote_data']).is_a?(Array)
|
152
172
|
self.remote_data = value
|
@@ -174,6 +194,7 @@ module MergeHRISClient
|
|
174
194
|
self.class == o.class &&
|
175
195
|
id == o.id &&
|
176
196
|
remote_id == o.remote_id &&
|
197
|
+
name == o.name &&
|
177
198
|
phone_number == o.phone_number &&
|
178
199
|
street_1 == o.street_1 &&
|
179
200
|
street_2 == o.street_2 &&
|
@@ -181,6 +202,7 @@ module MergeHRISClient
|
|
181
202
|
state == o.state &&
|
182
203
|
zip_code == o.zip_code &&
|
183
204
|
country == o.country &&
|
205
|
+
location_type == o.location_type &&
|
184
206
|
remote_data == o.remote_data
|
185
207
|
end
|
186
208
|
|
@@ -193,7 +215,7 @@ module MergeHRISClient
|
|
193
215
|
# Calculates hash code according to all attributes.
|
194
216
|
# @return [Integer] Hash code
|
195
217
|
def hash
|
196
|
-
[id, remote_id, phone_number, street_1, street_2, city, state, zip_code, country, remote_data].hash
|
218
|
+
[id, remote_id, name, phone_number, street_1, street_2, city, state, zip_code, country, location_type, remote_data].hash
|
197
219
|
end
|
198
220
|
|
199
221
|
# Builds the object from hash
|
@@ -236,7 +258,7 @@ module MergeHRISClient
|
|
236
258
|
when :Date
|
237
259
|
Date.parse(value)
|
238
260
|
when :String
|
239
|
-
value
|
261
|
+
value
|
240
262
|
when :Integer
|
241
263
|
value.to_i
|
242
264
|
when :Float
|
@@ -0,0 +1,36 @@
|
|
1
|
+
=begin
|
2
|
+
#Merge HRIS API
|
3
|
+
|
4
|
+
#The unified API for building rich integrations with multiple HR Information System platforms.
|
5
|
+
|
6
|
+
The version of the OpenAPI document: 1.0
|
7
|
+
Contact: hello@merge.dev
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
OpenAPI Generator version: 5.1.1
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require 'date'
|
14
|
+
require 'time'
|
15
|
+
|
16
|
+
module MergeHRISClient
|
17
|
+
class LocationTypeEnum
|
18
|
+
HOME = "HOME".freeze
|
19
|
+
WORK = "WORK".freeze
|
20
|
+
|
21
|
+
# Builds the enum from string
|
22
|
+
# @param [String] The enum value in the form of the string
|
23
|
+
# @return [String] The enum value
|
24
|
+
def self.build_from_hash(value)
|
25
|
+
new.build_from_hash(value)
|
26
|
+
end
|
27
|
+
|
28
|
+
# Builds the enum from string
|
29
|
+
# @param [String] The enum value in the form of the string
|
30
|
+
# @return [String] The enum value
|
31
|
+
def build_from_hash(value)
|
32
|
+
value
|
33
|
+
end
|
34
|
+
end
|
35
|
+
|
36
|
+
end
|
@@ -6,7 +6,7 @@
|
|
6
6
|
The version of the OpenAPI document: 1.0
|
7
7
|
Contact: hello@merge.dev
|
8
8
|
Generated by: https://openapi-generator.tech
|
9
|
-
OpenAPI Generator version: 5.
|
9
|
+
OpenAPI Generator version: 5.1.1
|
10
10
|
|
11
11
|
=end
|
12
12
|
|
@@ -32,8 +32,8 @@ module MergeHRISClient
|
|
32
32
|
# @param [String] The enum value in the form of the string
|
33
33
|
# @return [String] The enum value
|
34
34
|
def build_from_hash(value)
|
35
|
-
constantValues = MaritalStatusEnum.constants.select { |c| MaritalStatusEnum::const_get(c) == value }
|
36
35
|
value
|
37
36
|
end
|
38
37
|
end
|
38
|
+
|
39
39
|
end
|
@@ -34,8 +34,8 @@ module MergeHRISClient
|
|
34
34
|
# @param [String] The enum value in the form of the string
|
35
35
|
# @return [String] The enum value
|
36
36
|
def build_from_hash(value)
|
37
|
-
constantValues = MethodEnum.constants.select { |c| MethodEnum::const_get(c) == value }
|
38
37
|
value
|
39
38
|
end
|
40
39
|
end
|
40
|
+
|
41
41
|
end
|