diff --git a/.speakeasy/gen.lock b/.speakeasy/gen.lock index 57aca509..ae286507 100755 --- a/.speakeasy/gen.lock +++ b/.speakeasy/gen.lock @@ -1,12 +1,12 @@ lockVersion: 2.0.0 id: 482384cc-3b98-4ced-bd0b-14aa8b3e0053 management: - docChecksum: c3fc20cf94c9a3aab354b89abde7c574 + docChecksum: 4223928ae6936b081003abaa85c61cdc docVersion: 1.0.0 speakeasyVersion: 1.531.4 generationVersion: 2.570.4 - releaseVersion: 0.27.0 - configChecksum: 621578b3e725f235bf5e8c972a1d84c3 + releaseVersion: 0.29.0 + configChecksum: c43aa30f771dca03f756dfc96c985c72 repoURL: https://github.com/StackOneHQ/stackone-client-ruby.git repoSubDirectory: . installationURL: https://github.com/StackOneHQ/stackone-client-ruby @@ -66,6 +66,8 @@ generatedFiles: - docs/models/operations/atsgetapplicationcustomfielddefinitionqueryparamfilter.md - docs/models/operations/atsgetapplicationcustomfielddefinitionrequest.md - docs/models/operations/atsgetapplicationcustomfielddefinitionresponse.md + - docs/models/operations/atsgetapplicationdocumentcategoryrequest.md + - docs/models/operations/atsgetapplicationdocumentcategoryresponse.md - docs/models/operations/atsgetapplicationdocumentrequest.md - docs/models/operations/atsgetapplicationdocumentresponse.md - docs/models/operations/atsgetapplicationnoterequest.md @@ -122,6 +124,9 @@ generatedFiles: - docs/models/operations/atslistapplicationcustomfielddefinitionsqueryparamfilter.md - docs/models/operations/atslistapplicationcustomfielddefinitionsrequest.md - docs/models/operations/atslistapplicationcustomfielddefinitionsresponse.md + - docs/models/operations/atslistapplicationdocumentcategoriesqueryparamfilter.md + - docs/models/operations/atslistapplicationdocumentcategoriesrequest.md + - docs/models/operations/atslistapplicationdocumentcategoriesresponse.md - docs/models/operations/atslistapplicationdocumentsqueryparamfilter.md - docs/models/operations/atslistapplicationdocumentsrequest.md - docs/models/operations/atslistapplicationdocumentsresponse.md @@ -298,6 +303,8 @@ generatedFiles: - docs/models/operations/hrisgetlocationresponse.md - docs/models/operations/hrisgetpositionrequest.md - docs/models/operations/hrisgetpositionresponse.md + - docs/models/operations/hrisgetshiftrequest.md + - docs/models/operations/hrisgetshiftresponse.md - docs/models/operations/hrisgettaskrequest.md - docs/models/operations/hrisgettaskresponse.md - docs/models/operations/hrisgetteamgrouprequest.md @@ -378,6 +385,10 @@ generatedFiles: - docs/models/operations/hrislistpositionsqueryparamfilter.md - docs/models/operations/hrislistpositionsrequest.md - docs/models/operations/hrislistpositionsresponse.md + - docs/models/operations/hrislistshiftsqueryparamfilter.md + - docs/models/operations/hrislistshiftsqueryparamstatus.md + - docs/models/operations/hrislistshiftsrequest.md + - docs/models/operations/hrislistshiftsresponse.md - docs/models/operations/hrislisttasksqueryparamfilter.md - docs/models/operations/hrislisttasksrequest.md - docs/models/operations/hrislisttasksresponse.md @@ -626,6 +637,7 @@ generatedFiles: - docs/models/shared/applicationspaginated.md - docs/models/shared/applicationstatus.md - docs/models/shared/applicationvalue.md + - docs/models/shared/approvalstatus.md - docs/models/shared/archived.md - docs/models/shared/assessmentpackage.md - docs/models/shared/assessmentpackagepaginated.md @@ -930,6 +942,7 @@ generatedFiles: - docs/models/shared/customfields4.md - docs/models/shared/customfieldsvalue.md - docs/models/shared/custommappingerror.md + - docs/models/shared/data.md - docs/models/shared/deleteresult.md - docs/models/shared/department.md - docs/models/shared/departmentresult.md @@ -1297,6 +1310,24 @@ generatedFiles: - docs/models/shared/hrislocationsourcevalue.md - docs/models/shared/hrislocationspaginated.md - docs/models/shared/hrislocationvalue.md + - docs/models/shared/hrisshift.md + - docs/models/shared/hrisshift4.md + - docs/models/shared/hrisshiftresult.md + - docs/models/shared/hrisshiftresult4.md + - docs/models/shared/hrisshiftresultapprovalstatus.md + - docs/models/shared/hrisshiftresultschemas4.md + - docs/models/shared/hrisshiftresultschemassourcevalue.md + - docs/models/shared/hrisshiftresultschemasvalue.md + - docs/models/shared/hrisshiftresultsourcevalue.md + - docs/models/shared/hrisshiftresultstatus.md + - docs/models/shared/hrisshiftresultvalue.md + - docs/models/shared/hrisshiftschemas4.md + - docs/models/shared/hrisshiftschemassourcevalue.md + - docs/models/shared/hrisshiftschemasvalue.md + - docs/models/shared/hrisshiftsourcevalue.md + - docs/models/shared/hrisshiftspaginated.md + - docs/models/shared/hrisshiftstatus.md + - docs/models/shared/hrisshiftvalue.md - docs/models/shared/hristeam.md - docs/models/shared/hristeam4.md - docs/models/shared/hristeamsourcevalue.md @@ -1738,6 +1769,7 @@ generatedFiles: - docs/models/shared/secrets.md - docs/models/shared/security.md - docs/models/shared/setupinformation.md + - docs/models/shared/shiftbreak.md - docs/models/shared/skillresult.md - docs/models/shared/skills.md - docs/models/shared/skills2.md @@ -1963,6 +1995,8 @@ generatedFiles: - lib/stack_one/models/operations/ats_get_application_custom_field_definition_queryparam_filter.rb - lib/stack_one/models/operations/ats_get_application_custom_field_definition_request.rb - lib/stack_one/models/operations/ats_get_application_custom_field_definition_response.rb + - lib/stack_one/models/operations/ats_get_application_document_category_request.rb + - lib/stack_one/models/operations/ats_get_application_document_category_response.rb - lib/stack_one/models/operations/ats_get_application_document_request.rb - lib/stack_one/models/operations/ats_get_application_document_response.rb - lib/stack_one/models/operations/ats_get_application_note_request.rb @@ -2019,6 +2053,9 @@ generatedFiles: - lib/stack_one/models/operations/ats_list_application_custom_field_definitions_queryparam_filter.rb - lib/stack_one/models/operations/ats_list_application_custom_field_definitions_request.rb - lib/stack_one/models/operations/ats_list_application_custom_field_definitions_response.rb + - lib/stack_one/models/operations/ats_list_application_document_categories_queryparam_filter.rb + - lib/stack_one/models/operations/ats_list_application_document_categories_request.rb + - lib/stack_one/models/operations/ats_list_application_document_categories_response.rb - lib/stack_one/models/operations/ats_list_application_documents_queryparam_filter.rb - lib/stack_one/models/operations/ats_list_application_documents_request.rb - lib/stack_one/models/operations/ats_list_application_documents_response.rb @@ -2195,6 +2232,8 @@ generatedFiles: - lib/stack_one/models/operations/hris_get_location_response.rb - lib/stack_one/models/operations/hris_get_position_request.rb - lib/stack_one/models/operations/hris_get_position_response.rb + - lib/stack_one/models/operations/hris_get_shift_request.rb + - lib/stack_one/models/operations/hris_get_shift_response.rb - lib/stack_one/models/operations/hris_get_task_request.rb - lib/stack_one/models/operations/hris_get_task_response.rb - lib/stack_one/models/operations/hris_get_team_group_request.rb @@ -2275,6 +2314,10 @@ generatedFiles: - lib/stack_one/models/operations/hris_list_positions_queryparam_filter.rb - lib/stack_one/models/operations/hris_list_positions_request.rb - lib/stack_one/models/operations/hris_list_positions_response.rb + - lib/stack_one/models/operations/hris_list_shifts_queryparam_filter.rb + - lib/stack_one/models/operations/hris_list_shifts_queryparam_status.rb + - lib/stack_one/models/operations/hris_list_shifts_request.rb + - lib/stack_one/models/operations/hris_list_shifts_response.rb - lib/stack_one/models/operations/hris_list_tasks_queryparam_filter.rb - lib/stack_one/models/operations/hris_list_tasks_request.rb - lib/stack_one/models/operations/hris_list_tasks_response.rb @@ -2524,6 +2567,7 @@ generatedFiles: - lib/stack_one/models/shared/applicationchangespaginated.rb - lib/stack_one/models/shared/applicationresult.rb - lib/stack_one/models/shared/applicationspaginated.rb + - lib/stack_one/models/shared/approval_status.rb - lib/stack_one/models/shared/archived.rb - lib/stack_one/models/shared/assessmentpackage.rb - lib/stack_one/models/shared/assessmentpackagepaginated.rb @@ -2828,6 +2872,7 @@ generatedFiles: - lib/stack_one/models/shared/customfields_4.rb - lib/stack_one/models/shared/customfields_value.rb - lib/stack_one/models/shared/custommappingerror.rb + - lib/stack_one/models/shared/data.rb - lib/stack_one/models/shared/deleteresult.rb - lib/stack_one/models/shared/department.rb - lib/stack_one/models/shared/departmentresult.rb @@ -3195,6 +3240,24 @@ generatedFiles: - lib/stack_one/models/shared/hrislocation_value.rb - lib/stack_one/models/shared/hrislocationresult.rb - lib/stack_one/models/shared/hrislocationspaginated.rb + - lib/stack_one/models/shared/hrisshift.rb + - lib/stack_one/models/shared/hrisshift_4.rb + - lib/stack_one/models/shared/hrisshift_schemas_4.rb + - lib/stack_one/models/shared/hrisshift_schemas_source_value.rb + - lib/stack_one/models/shared/hrisshift_schemas_value.rb + - lib/stack_one/models/shared/hrisshift_source_value.rb + - lib/stack_one/models/shared/hrisshift_status.rb + - lib/stack_one/models/shared/hrisshift_value.rb + - lib/stack_one/models/shared/hrisshiftresult.rb + - lib/stack_one/models/shared/hrisshiftresult_4.rb + - lib/stack_one/models/shared/hrisshiftresult_approval_status.rb + - lib/stack_one/models/shared/hrisshiftresult_schemas_4.rb + - lib/stack_one/models/shared/hrisshiftresult_schemas_source_value.rb + - lib/stack_one/models/shared/hrisshiftresult_schemas_value.rb + - lib/stack_one/models/shared/hrisshiftresult_source_value.rb + - lib/stack_one/models/shared/hrisshiftresult_status.rb + - lib/stack_one/models/shared/hrisshiftresult_value.rb + - lib/stack_one/models/shared/hrisshiftspaginated.rb - lib/stack_one/models/shared/hristeam.rb - lib/stack_one/models/shared/hristeam_4.rb - lib/stack_one/models/shared/hristeam_source_value.rb @@ -3636,6 +3699,7 @@ generatedFiles: - lib/stack_one/models/shared/secrets.rb - lib/stack_one/models/shared/security.rb - lib/stack_one/models/shared/setup_information.rb + - lib/stack_one/models/shared/shiftbreak.rb - lib/stack_one/models/shared/skillresult.rb - lib/stack_one/models/shared/skills.rb - lib/stack_one/models/shared/skills_2.rb @@ -4643,6 +4707,42 @@ examples: application/json: {"message": "Not Implemented", "statusCode": 501, "timestamp": "2023-05-30T00:00:00.000Z"} "502": application/json: {"message": "Bad Gateway", "statusCode": 502, "timestamp": "2023-05-30T00:00:00.000Z"} + ats_get_application_document_category: + speakeasy-default-ats-get-application-document-category: + parameters: + path: + id: "" + query: + fields: "id,remote_id,name,active" + header: + x-account-id: "" + responses: + "200": + application/json: {"data": {"active": true, "id": "1687-3", "name": "1687-4", "remote_id": "8187e5da-dc77-475e-9949-af0f1fa4e4e3"}} + "400": + application/json: {"data": {"message": "Bad Request", "statusCode": 400}, "message": "Bad Request", "provider_errors": [{"status": 400, "url": "https://api.provider.com/v1/resource"}, {"status": 400, "url": "https://api.provider.com/v1/resource"}, {"status": 400, "url": "https://api.provider.com/v1/resource"}], "statusCode": 400, "timestamp": "2023-05-30T00:00:00.000Z"} + "401": + application/json: {"message": "Unauthorized", "statusCode": 401, "timestamp": "2023-05-30T00:00:00.000Z"} + "403": + application/json: {"message": "Forbidden resource", "statusCode": 403, "timestamp": "2023-05-30T00:00:00.000Z"} + "404": + application/json: {"message": "Not Found", "statusCode": 404, "timestamp": "2023-05-30T00:00:00.000Z"} + "408": + application/json: {"message": "Request timed out", "statusCode": 408, "timestamp": "2023-05-30T00:00:00.000Z"} + "409": + application/json: {"message": "Conflict", "statusCode": 409, "timestamp": "2023-05-30T00:00:00.000Z"} + "412": + application/json: {"message": "Precondition failed", "statusCode": 412, "timestamp": "2023-05-30T00:00:00.000Z"} + "422": + application/json: {"message": "Unprocessable Entity", "statusCode": 422, "timestamp": "2023-05-30T00:00:00.000Z"} + "429": + application/json: {"message": "Too many requests", "statusCode": 429, "timestamp": "2023-05-30T00:00:00.000Z"} + "500": + application/json: {"message": "Internal server error", "statusCode": 500, "timestamp": "2023-05-30T00:00:00.000Z"} + "501": + application/json: {"message": "Not Implemented", "statusCode": 501, "timestamp": "2023-05-30T00:00:00.000Z"} + "502": + application/json: {"message": "Bad Gateway", "statusCode": 502, "timestamp": "2023-05-30T00:00:00.000Z"} ats_get_application_note: speakeasy-default-ats-get-application-note: parameters: @@ -5520,6 +5620,42 @@ examples: application/json: {"message": "Not Implemented", "statusCode": 501, "timestamp": "2023-05-30T00:00:00.000Z"} "502": application/json: {"message": "Bad Gateway", "statusCode": 502, "timestamp": "2023-05-30T00:00:00.000Z"} + ats_list_application_document_categories: + speakeasy-default-ats-list-application-document-categories: + parameters: + query: + fields: "id,remote_id,name,active" + filter: {"updated_after": "2020-01-01T00:00:00.000Z"} + updated_after: "2020-01-01T00:00:00.000Z" + header: + x-account-id: "" + responses: + "200": + application/json: {"data": [{"active": true, "id": "1687-3", "name": "1687-4", "remote_id": "8187e5da-dc77-475e-9949-af0f1fa4e4e3"}]} + "400": + application/json: {"data": {"message": "Bad Request", "statusCode": 400}, "message": "Bad Request", "provider_errors": [{"status": 400, "url": "https://api.provider.com/v1/resource"}, {"status": 400, "url": "https://api.provider.com/v1/resource"}], "statusCode": 400, "timestamp": "2023-05-30T00:00:00.000Z"} + "401": + application/json: {"message": "Unauthorized", "statusCode": 401, "timestamp": "2023-05-30T00:00:00.000Z"} + "403": + application/json: {"message": "Forbidden resource", "statusCode": 403, "timestamp": "2023-05-30T00:00:00.000Z"} + "404": + application/json: {"message": "Not Found", "statusCode": 404, "timestamp": "2023-05-30T00:00:00.000Z"} + "408": + application/json: {"message": "Request timed out", "statusCode": 408, "timestamp": "2023-05-30T00:00:00.000Z"} + "409": + application/json: {"message": "Conflict", "statusCode": 409, "timestamp": "2023-05-30T00:00:00.000Z"} + "412": + application/json: {"message": "Precondition failed", "statusCode": 412, "timestamp": "2023-05-30T00:00:00.000Z"} + "422": + application/json: {"message": "Unprocessable Entity", "statusCode": 422, "timestamp": "2023-05-30T00:00:00.000Z"} + "429": + application/json: {"message": "Too many requests", "statusCode": 429, "timestamp": "2023-05-30T00:00:00.000Z"} + "500": + application/json: {"message": "Internal server error", "statusCode": 500, "timestamp": "2023-05-30T00:00:00.000Z"} + "501": + application/json: {"message": "Not Implemented", "statusCode": 501, "timestamp": "2023-05-30T00:00:00.000Z"} + "502": + application/json: {"message": "Bad Gateway", "statusCode": 502, "timestamp": "2023-05-30T00:00:00.000Z"} ats_list_application_documents: speakeasy-default-ats-list-application-documents: parameters: @@ -8179,6 +8315,41 @@ examples: application/json: {"message": "Not Implemented", "statusCode": 501, "timestamp": "2023-05-30T00:00:00.000Z"} "502": application/json: {"message": "Bad Gateway", "statusCode": 502, "timestamp": "2023-05-30T00:00:00.000Z"} + hris_get_shift: + speakeasy-default-hris-get-shift: + parameters: + path: + id: "" + query: {} + header: + x-account-id: "" + responses: + "200": + application/json: {"data": {"approval_status": {"source_value": "Approved", "value": "approved"}, "break_duration": "PT1H30M", "breaks": [{"created_at": "2024-03-20T10:00:00Z", "duration": "PT1H", "end_time": "2024-03-20T13:00:00Z", "id": "break_123456789", "is_paid": true, "start_time": "2024-03-20T12:00:00Z", "updated_at": "2024-03-20T10:00:00Z"}], "company_id": "comp_123456789", "created_at": "2024-03-20T08:00:00Z", "employee_id": "emp_123456789", "end_time": "2024-03-20T17:00:00Z", "id": "8187e5da-dc77-475e-9949-af0f1fa4e4e3", "location_id": "loc_123456789", "remote_id": "8187e5da-dc77-475e-9949-af0f1fa4e4e3", "start_time": "2024-03-20T09:00:00Z", "status": {"source_value": "Confirmed", "value": "confirmed"}, "updated_at": "2024-03-20T08:00:00Z"}} + "400": + application/json: {"data": {"message": "Bad Request", "statusCode": 400}, "message": "Bad Request", "provider_errors": [{"status": 400, "url": "https://api.provider.com/v1/resource"}, {"status": 400, "url": "https://api.provider.com/v1/resource"}, {"status": 400, "url": "https://api.provider.com/v1/resource"}], "statusCode": 400, "timestamp": "2023-05-30T00:00:00.000Z"} + "401": + application/json: {"message": "Unauthorized", "statusCode": 401, "timestamp": "2023-05-30T00:00:00.000Z"} + "403": + application/json: {"message": "Forbidden resource", "statusCode": 403, "timestamp": "2023-05-30T00:00:00.000Z"} + "404": + application/json: {"message": "Not Found", "statusCode": 404, "timestamp": "2023-05-30T00:00:00.000Z"} + "408": + application/json: {"message": "Request timed out", "statusCode": 408, "timestamp": "2023-05-30T00:00:00.000Z"} + "409": + application/json: {"message": "Conflict", "statusCode": 409, "timestamp": "2023-05-30T00:00:00.000Z"} + "412": + application/json: {"message": "Precondition failed", "statusCode": 412, "timestamp": "2023-05-30T00:00:00.000Z"} + "422": + application/json: {"message": "Unprocessable Entity", "statusCode": 422, "timestamp": "2023-05-30T00:00:00.000Z"} + "429": + application/json: {"message": "Too many requests", "statusCode": 429, "timestamp": "2023-05-30T00:00:00.000Z"} + "500": + application/json: {"message": "Internal server error", "statusCode": 500, "timestamp": "2023-05-30T00:00:00.000Z"} + "501": + application/json: {"message": "Not Implemented", "statusCode": 501, "timestamp": "2023-05-30T00:00:00.000Z"} + "502": + application/json: {"message": "Bad Gateway", "statusCode": 502, "timestamp": "2023-05-30T00:00:00.000Z"} hris_get_task: speakeasy-default-hris-get-task: parameters: @@ -9248,6 +9419,41 @@ examples: application/json: {"message": "Not Implemented", "statusCode": 501, "timestamp": "2023-05-30T00:00:00.000Z"} "502": application/json: {"message": "Bad Gateway", "statusCode": 502, "timestamp": "2023-05-30T00:00:00.000Z"} + hris_list_shifts: + speakeasy-default-hris-list-shifts: + parameters: + query: + filter: {"updated_after": "2020-01-01T00:00:00.000Z"} + updated_after: "2020-01-01T00:00:00.000Z" + header: + x-account-id: "" + responses: + "200": + application/json: {"data": [{"approval_status": {"source_value": "Approved", "value": "approved"}, "break_duration": "PT1H30M", "breaks": [{"created_at": "2024-03-20T10:00:00Z", "duration": "PT1H", "end_time": "2024-03-20T13:00:00Z", "id": "break_123456789", "is_paid": true, "start_time": "2024-03-20T12:00:00Z", "updated_at": "2024-03-20T10:00:00Z"}, {"created_at": "2024-03-20T10:00:00Z", "duration": "PT1H", "end_time": "2024-03-20T13:00:00Z", "id": "break_123456789", "is_paid": true, "start_time": "2024-03-20T12:00:00Z", "updated_at": "2024-03-20T10:00:00Z"}], "company_id": "comp_123456789", "created_at": "2024-03-20T08:00:00Z", "employee_id": "emp_123456789", "end_time": "2024-03-20T17:00:00Z", "id": "8187e5da-dc77-475e-9949-af0f1fa4e4e3", "location_id": "loc_123456789", "remote_id": "8187e5da-dc77-475e-9949-af0f1fa4e4e3", "start_time": "2024-03-20T09:00:00Z", "status": {"source_value": "Confirmed", "value": "confirmed"}, "updated_at": "2024-03-20T08:00:00Z"}, {"approval_status": {"source_value": "Approved", "value": "approved"}, "break_duration": "PT1H30M", "breaks": [{"created_at": "2024-03-20T10:00:00Z", "duration": "PT1H", "end_time": "2024-03-20T13:00:00Z", "id": "break_123456789", "is_paid": true, "start_time": "2024-03-20T12:00:00Z", "updated_at": "2024-03-20T10:00:00Z"}, {"created_at": "2024-03-20T10:00:00Z", "duration": "PT1H", "end_time": "2024-03-20T13:00:00Z", "id": "break_123456789", "is_paid": true, "start_time": "2024-03-20T12:00:00Z", "updated_at": "2024-03-20T10:00:00Z"}], "company_id": "comp_123456789", "created_at": "2024-03-20T08:00:00Z", "employee_id": "emp_123456789", "end_time": "2024-03-20T17:00:00Z", "id": "8187e5da-dc77-475e-9949-af0f1fa4e4e3", "location_id": "loc_123456789", "remote_id": "8187e5da-dc77-475e-9949-af0f1fa4e4e3", "start_time": "2024-03-20T09:00:00Z", "status": {"source_value": "Confirmed", "value": "confirmed"}, "updated_at": "2024-03-20T08:00:00Z"}]} + "400": + application/json: {"data": {"message": "Bad Request", "statusCode": 400}, "message": "Bad Request", "provider_errors": [{"status": 400, "url": "https://api.provider.com/v1/resource"}, {"status": 400, "url": "https://api.provider.com/v1/resource"}, {"status": 400, "url": "https://api.provider.com/v1/resource"}], "statusCode": 400, "timestamp": "2023-05-30T00:00:00.000Z"} + "401": + application/json: {"message": "Unauthorized", "statusCode": 401, "timestamp": "2023-05-30T00:00:00.000Z"} + "403": + application/json: {"message": "Forbidden resource", "statusCode": 403, "timestamp": "2023-05-30T00:00:00.000Z"} + "404": + application/json: {"message": "Not Found", "statusCode": 404, "timestamp": "2023-05-30T00:00:00.000Z"} + "408": + application/json: {"message": "Request timed out", "statusCode": 408, "timestamp": "2023-05-30T00:00:00.000Z"} + "409": + application/json: {"message": "Conflict", "statusCode": 409, "timestamp": "2023-05-30T00:00:00.000Z"} + "412": + application/json: {"message": "Precondition failed", "statusCode": 412, "timestamp": "2023-05-30T00:00:00.000Z"} + "422": + application/json: {"message": "Unprocessable Entity", "statusCode": 422, "timestamp": "2023-05-30T00:00:00.000Z"} + "429": + application/json: {"message": "Too many requests", "statusCode": 429, "timestamp": "2023-05-30T00:00:00.000Z"} + "500": + application/json: {"message": "Internal server error", "statusCode": 500, "timestamp": "2023-05-30T00:00:00.000Z"} + "501": + application/json: {"message": "Not Implemented", "statusCode": 501, "timestamp": "2023-05-30T00:00:00.000Z"} + "502": + application/json: {"message": "Bad Gateway", "statusCode": 502, "timestamp": "2023-05-30T00:00:00.000Z"} hris_list_tasks: speakeasy-default-hris-list-tasks: parameters: diff --git a/.speakeasy/workflow.lock b/.speakeasy/workflow.lock index 952cbe8c..93c973f7 100644 --- a/.speakeasy/workflow.lock +++ b/.speakeasy/workflow.lock @@ -2,20 +2,20 @@ speakeasyVersion: 1.531.4 sources: my-source: sourceNamespace: my-source - sourceRevisionDigest: sha256:065820898b2fa3bc8907f9a7367650e8b92b4ff658a1adc049fd0a8e24c8cc11 - sourceBlobDigest: sha256:a02ccd55af272c898d16d06b0a9cc651a97b78b5ceac8d1c0ffdc2b8a52e8daa + sourceRevisionDigest: sha256:cae6b42cb2c2dcc85ace9940c1bc35724d85d24da6e62a09c784ec978878d316 + sourceBlobDigest: sha256:5aa452c2840a0b2ae63d7e7a8502940452c77a2a9660f6f295a560b5ed5a4780 tags: - latest - - speakeasy-sdk-regen-1752483877 + - speakeasy-sdk-regen-1753088668 - 1.0.0 targets: StackOneRubyClient: source: my-source sourceNamespace: my-source - sourceRevisionDigest: sha256:065820898b2fa3bc8907f9a7367650e8b92b4ff658a1adc049fd0a8e24c8cc11 - sourceBlobDigest: sha256:a02ccd55af272c898d16d06b0a9cc651a97b78b5ceac8d1c0ffdc2b8a52e8daa + sourceRevisionDigest: sha256:cae6b42cb2c2dcc85ace9940c1bc35724d85d24da6e62a09c784ec978878d316 + sourceBlobDigest: sha256:5aa452c2840a0b2ae63d7e7a8502940452c77a2a9660f6f295a560b5ed5a4780 codeSamplesNamespace: code-samples-ruby-stackonerubyclient - codeSamplesRevisionDigest: sha256:afb7199a877a6d1a944ce990b56d3aff4fd24c053b175fa0c210ad19093f57f4 + codeSamplesRevisionDigest: sha256:d2c505d7d66510a4f6fecab3b390b997c3016c2ec2dded0169c9216b79dd0bd4 workflow: workflowVersion: 1.0.0 speakeasyVersion: latest diff --git a/README.md b/README.md index 6adad6f6..0ceb0c7e 100644 --- a/README.md +++ b/README.md @@ -133,6 +133,7 @@ end * [get_application](docs/sdks/ats/README.md#get_application) - Get Application * [get_application_custom_field_definition](docs/sdks/ats/README.md#get_application_custom_field_definition) - Get Application Custom Field Definition * [get_application_document](docs/sdks/ats/README.md#get_application_document) - Get Application Document +* [get_application_document_category](docs/sdks/ats/README.md#get_application_document_category) - Get Application Document Category * [get_application_note](docs/sdks/ats/README.md#get_application_note) - Get Application Note * [get_application_offer](docs/sdks/ats/README.md#get_application_offer) - Get Application Offer * [get_application_scheduled_interview](docs/sdks/ats/README.md#get_application_scheduled_interview) - Get Applications scheduled interview @@ -157,6 +158,7 @@ end * [get_user](docs/sdks/ats/README.md#get_user) - Get User * [list_application_changes](docs/sdks/ats/README.md#list_application_changes) - List Application Changes * [list_application_custom_field_definitions](docs/sdks/ats/README.md#list_application_custom_field_definitions) - List Application Custom Field Definitions +* [list_application_document_categories](docs/sdks/ats/README.md#list_application_document_categories) - List Application Document Categories * [list_application_documents](docs/sdks/ats/README.md#list_application_documents) - List Application Documents * [list_application_notes](docs/sdks/ats/README.md#list_application_notes) - List Application Notes * [list_application_scorecards](docs/sdks/ats/README.md#list_application_scorecards) - List Application Scorecards @@ -246,6 +248,7 @@ end * [get_job](docs/sdks/hris/README.md#get_job) - Get Job * [get_location](docs/sdks/hris/README.md#get_location) - Get Work Location * [get_position](docs/sdks/hris/README.md#get_position) - Get Position +* [get_shift](docs/sdks/hris/README.md#get_shift) - Get Shift * [get_task](docs/sdks/hris/README.md#get_task) - Get Task * [get_team_group](docs/sdks/hris/README.md#get_team_group) - Get Team Group * [get_time_entries](docs/sdks/hris/README.md#get_time_entries) - Get Time Entry @@ -275,6 +278,7 @@ end * [list_jobs](docs/sdks/hris/README.md#list_jobs) - List Jobs * [list_locations](docs/sdks/hris/README.md#list_locations) - List Work Locations * [list_positions](docs/sdks/hris/README.md#list_positions) - List Positions +* [list_shifts](docs/sdks/hris/README.md#list_shifts) - List Shifts * [list_tasks](docs/sdks/hris/README.md#list_tasks) - List Tasks * [list_team_groups](docs/sdks/hris/README.md#list_team_groups) - List Team Groups * [list_time_entries](docs/sdks/hris/README.md#list_time_entries) - List Time Entries diff --git a/RELEASES.md b/RELEASES.md index 6bc057e9..9dc5db0e 100644 --- a/RELEASES.md +++ b/RELEASES.md @@ -898,4 +898,14 @@ Based on: ### Generated - [ruby v0.27.0] . ### Releases -- [Ruby Gems v0.27.0] https://rubygems.org/gems/stackone_client/versions/0.27.0 - . \ No newline at end of file +- [Ruby Gems v0.27.0] https://rubygems.org/gems/stackone_client/versions/0.27.0 - . + +## 2025-07-21 09:04:10 +### Changes +Based on: +- OpenAPI Doc +- Speakeasy CLI 1.531.4 (2.570.4) https://github.com/speakeasy-api/speakeasy +### Generated +- [ruby v0.29.0] . +### Releases +- [Ruby Gems v0.29.0] https://rubygems.org/gems/stackone_client/versions/0.29.0 - . \ No newline at end of file diff --git a/codeSamples.yaml b/codeSamples.yaml index 8fc6d9bc..dea088ce 100644 --- a/codeSamples.yaml +++ b/codeSamples.yaml @@ -369,6 +369,18 @@ actions: - "lang": "ruby" "label": "ats_get_department" "source": "require 'stackone_client'\n\ns = ::StackOne::StackOne.new(\n security: Models::Shared::Security.new(\n username: \"\",\n password: \"\",\n ),\n )\n\nreq = Models::Operations::AtsGetDepartmentRequest.new(\n id: \"\",\n fields_: \"id,remote_id,name\",\n x_account_id: \"\",\n)\n\nres = s.ats.get_department(req)\n\nif ! res.department_result.nil?\n # handle response\nend" + - target: $["paths"]["/unified/ats/documents/application_categories"]["get"] + update: + "x-codeSamples": + - "lang": "ruby" + "label": "ats_list_application_document_categories" + "source": "require 'stackone_client'\n\ns = ::StackOne::StackOne.new(\n security: Models::Shared::Security.new(\n username: \"\",\n password: \"\",\n ),\n )\n\nreq = Models::Operations::AtsListApplicationDocumentCategoriesRequest.new(\n fields_: \"id,remote_id,name,active\",\n filter: Models::Operations::AtsListApplicationDocumentCategoriesQueryParamFilter.new(\n updated_after: \"2020-01-01T00:00:00.000Z\",\n ),\n x_account_id: \"\",\n)\n\nres = s.ats.list_application_document_categories(req)\n\nif ! res.reference_paginated.nil?\n # handle response\nend" + - target: $["paths"]["/unified/ats/documents/application_categories/{id}"]["get"] + update: + "x-codeSamples": + - "lang": "ruby" + "label": "ats_get_application_document_category" + "source": "require 'stackone_client'\n\ns = ::StackOne::StackOne.new(\n security: Models::Shared::Security.new(\n username: \"\",\n password: \"\",\n ),\n )\n\nreq = Models::Operations::AtsGetApplicationDocumentCategoryRequest.new(\n id: \"\",\n fields_: \"id,remote_id,name,active\",\n x_account_id: \"\",\n)\n\nres = s.ats.get_application_document_category(req)\n\nif ! res.reference_result.nil?\n # handle response\nend" - target: $["paths"]["/unified/ats/interview_stages"]["get"] update: "x-codeSamples": @@ -909,6 +921,18 @@ actions: - "lang": "ruby" "label": "hris_get_position" "source": "require 'stackone_client'\n\ns = ::StackOne::StackOne.new(\n security: Models::Shared::Security.new(\n username: \"\",\n password: \"\",\n ),\n )\n\nreq = Models::Operations::HrisGetPositionRequest.new(\n id: \"\",\n x_account_id: \"\",\n)\n\nres = s.hris.get_position(req)\n\nif ! res.position_result.nil?\n # handle response\nend" + - target: $["paths"]["/unified/hris/shifts"]["get"] + update: + "x-codeSamples": + - "lang": "ruby" + "label": "hris_list_shifts" + "source": "require 'stackone_client'\n\ns = ::StackOne::StackOne.new(\n security: Models::Shared::Security.new(\n username: \"\",\n password: \"\",\n ),\n )\n\nreq = Models::Operations::HrisListShiftsRequest.new(\n filter: Models::Operations::HrisListShiftsQueryParamFilter.new(\n updated_after: \"2020-01-01T00:00:00.000Z\",\n ),\n x_account_id: \"\",\n)\n\nres = s.hris.list_shifts(req)\n\nif ! res.hris_shifts_paginated.nil?\n # handle response\nend" + - target: $["paths"]["/unified/hris/shifts/{id}"]["get"] + update: + "x-codeSamples": + - "lang": "ruby" + "label": "hris_get_shift" + "source": "require 'stackone_client'\n\ns = ::StackOne::StackOne.new(\n security: Models::Shared::Security.new(\n username: \"\",\n password: \"\",\n ),\n )\n\nreq = Models::Operations::HrisGetShiftRequest.new(\n id: \"\",\n x_account_id: \"\",\n)\n\nres = s.hris.get_shift(req)\n\nif ! res.hris_shift_result.nil?\n # handle response\nend" - target: $["paths"]["/unified/hris/tasks"]["get"] update: "x-codeSamples": diff --git a/docs/models/operations/atsgetapplicationdocumentcategoryrequest.md b/docs/models/operations/atsgetapplicationdocumentcategoryrequest.md new file mode 100644 index 00000000..d9c61eef --- /dev/null +++ b/docs/models/operations/atsgetapplicationdocumentcategoryrequest.md @@ -0,0 +1,12 @@ +# AtsGetApplicationDocumentCategoryRequest + + +## Fields + +| Field | Type | Required | Description | Example | +| ------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------ | +| `fields_` | *T.nilable(::String)* | :heavy_minus_sign: | The comma separated list of fields that will be returned in the response (if empty, all fields are returned) | id,remote_id,name,active | +| `id` | *::String* | :heavy_check_mark: | N/A | | +| `proxy` | T::Hash[Symbol, *::Object*] | :heavy_minus_sign: | Query parameters that can be used to pass through parameters to the underlying provider request by surrounding them with 'proxy' key | | +| `raw` | *T.nilable(T::Boolean)* | :heavy_minus_sign: | Indicates that the raw request result should be returned in addition to the mapped result (default value is false) | | +| `x_account_id` | *::String* | :heavy_check_mark: | The account identifier | | \ No newline at end of file diff --git a/docs/models/operations/atsgetapplicationdocumentcategoryresponse.md b/docs/models/operations/atsgetapplicationdocumentcategoryresponse.md new file mode 100644 index 00000000..2628e3e6 --- /dev/null +++ b/docs/models/operations/atsgetapplicationdocumentcategoryresponse.md @@ -0,0 +1,12 @@ +# AtsGetApplicationDocumentCategoryResponse + + +## Fields + +| Field | Type | Required | Description | +| ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------ | +| `content_type` | *::String* | :heavy_check_mark: | HTTP response content type for this operation | +| `headers` | T::Hash[Symbol, T::Array<*::String*>] | :heavy_check_mark: | N/A | +| `reference_result` | [T.nilable(Models::Shared::ReferenceResult)](../../models/shared/referenceresult.md) | :heavy_minus_sign: | The application document category with the given identifier was retrieved. | +| `status_code` | *::Integer* | :heavy_check_mark: | HTTP response status code for this operation | +| `raw_response` | [Faraday::Response](https://www.rubydoc.info/gems/faraday/Faraday/Response) | :heavy_check_mark: | Raw HTTP response; suitable for custom response parsing | \ No newline at end of file diff --git a/docs/models/operations/atslistapplicationdocumentcategoriesqueryparamfilter.md b/docs/models/operations/atslistapplicationdocumentcategoriesqueryparamfilter.md new file mode 100644 index 00000000..d730ceec --- /dev/null +++ b/docs/models/operations/atslistapplicationdocumentcategoriesqueryparamfilter.md @@ -0,0 +1,10 @@ +# AtsListApplicationDocumentCategoriesQueryParamFilter + +Filter parameters that allow greater customisation of the list response + + +## Fields + +| Field | Type | Required | Description | Example | +| ----------------------------------------------------------------------------- | ----------------------------------------------------------------------------- | ----------------------------------------------------------------------------- | ----------------------------------------------------------------------------- | ----------------------------------------------------------------------------- | +| `updated_after` | *T.nilable(::String)* | :heavy_minus_sign: | Use a string with a date to only select results updated after that given date | 2020-01-01T00:00:00.000Z | \ No newline at end of file diff --git a/docs/models/operations/atslistapplicationdocumentcategoriesrequest.md b/docs/models/operations/atslistapplicationdocumentcategoriesrequest.md new file mode 100644 index 00000000..e8c449d1 --- /dev/null +++ b/docs/models/operations/atslistapplicationdocumentcategoriesrequest.md @@ -0,0 +1,16 @@ +# AtsListApplicationDocumentCategoriesRequest + + +## Fields + +| Field | Type | Required | Description | Example | +| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | +| `fields_` | *T.nilable(::String)* | :heavy_minus_sign: | The comma separated list of fields that will be returned in the response (if empty, all fields are returned) | id,remote_id,name,active | +| `filter` | [T.nilable(Models::Operations::AtsListApplicationDocumentCategoriesQueryParamFilter)](../../models/operations/atslistapplicationdocumentcategoriesqueryparamfilter.md) | :heavy_minus_sign: | Filter parameters that allow greater customisation of the list response | | +| `next_` | *T.nilable(::String)* | :heavy_minus_sign: | The unified cursor | | +| ~~`page`~~ | *T.nilable(::String)* | :heavy_minus_sign: | : warning: ** DEPRECATED **: This will be removed in a future release, please migrate away from it as soon as possible.

The page number of the results to fetch | | +| `page_size` | *T.nilable(::String)* | :heavy_minus_sign: | The number of results per page (default value is 25) | | +| `proxy` | T::Hash[Symbol, *::Object*] | :heavy_minus_sign: | Query parameters that can be used to pass through parameters to the underlying provider request by surrounding them with 'proxy' key | | +| `raw` | *T.nilable(T::Boolean)* | :heavy_minus_sign: | Indicates that the raw request result should be returned in addition to the mapped result (default value is false) | | +| ~~`updated_after`~~ | *T.nilable(::String)* | :heavy_minus_sign: | : warning: ** DEPRECATED **: This will be removed in a future release, please migrate away from it as soon as possible.

Use a string with a date to only select results updated after that given date | 2020-01-01T00:00:00.000Z | +| `x_account_id` | *::String* | :heavy_check_mark: | The account identifier | | \ No newline at end of file diff --git a/docs/models/operations/atslistapplicationdocumentcategoriesresponse.md b/docs/models/operations/atslistapplicationdocumentcategoriesresponse.md new file mode 100644 index 00000000..056118f1 --- /dev/null +++ b/docs/models/operations/atslistapplicationdocumentcategoriesresponse.md @@ -0,0 +1,12 @@ +# AtsListApplicationDocumentCategoriesResponse + + +## Fields + +| Field | Type | Required | Description | +| ------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------ | +| `content_type` | *::String* | :heavy_check_mark: | HTTP response content type for this operation | +| `headers` | T::Hash[Symbol, T::Array<*::String*>] | :heavy_check_mark: | N/A | +| `reference_paginated` | [T.nilable(Models::Shared::ReferencePaginated)](../../models/shared/referencepaginated.md) | :heavy_minus_sign: | The list of application document categories were retrieved. | +| `status_code` | *::Integer* | :heavy_check_mark: | HTTP response status code for this operation | +| `raw_response` | [Faraday::Response](https://www.rubydoc.info/gems/faraday/Faraday/Response) | :heavy_check_mark: | Raw HTTP response; suitable for custom response parsing | \ No newline at end of file diff --git a/docs/models/operations/hrisgetshiftrequest.md b/docs/models/operations/hrisgetshiftrequest.md new file mode 100644 index 00000000..895e9985 --- /dev/null +++ b/docs/models/operations/hrisgetshiftrequest.md @@ -0,0 +1,12 @@ +# HrisGetShiftRequest + + +## Fields + +| Field | Type | Required | Description | +| ------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------ | +| `fields_` | *T.nilable(::String)* | :heavy_minus_sign: | The comma separated list of fields to return in the response (if empty, all fields are returned) | +| `id` | *::String* | :heavy_check_mark: | N/A | +| `proxy` | T::Hash[Symbol, *::Object*] | :heavy_minus_sign: | Query parameters that can be used to pass through parameters to the underlying provider request by surrounding them with 'proxy' key | +| `raw` | *T.nilable(T::Boolean)* | :heavy_minus_sign: | Indicates that the raw request result should be returned in addition to the mapped result (default value is false) | +| `x_account_id` | *::String* | :heavy_check_mark: | The account identifier | \ No newline at end of file diff --git a/docs/models/operations/hrisgetshiftresponse.md b/docs/models/operations/hrisgetshiftresponse.md new file mode 100644 index 00000000..c13d6c3c --- /dev/null +++ b/docs/models/operations/hrisgetshiftresponse.md @@ -0,0 +1,12 @@ +# HrisGetShiftResponse + + +## Fields + +| Field | Type | Required | Description | +| ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------ | +| `content_type` | *::String* | :heavy_check_mark: | HTTP response content type for this operation | +| `headers` | T::Hash[Symbol, T::Array<*::String*>] | :heavy_check_mark: | N/A | +| `hris_shift_result` | [T.nilable(Models::Shared::HrisShiftResult)](../../models/shared/hrisshiftresult.md) | :heavy_minus_sign: | The shift with the given identifier was retrieved. | +| `status_code` | *::Integer* | :heavy_check_mark: | HTTP response status code for this operation | +| `raw_response` | [Faraday::Response](https://www.rubydoc.info/gems/faraday/Faraday/Response) | :heavy_check_mark: | Raw HTTP response; suitable for custom response parsing | \ No newline at end of file diff --git a/docs/models/operations/hrislistshiftsqueryparamfilter.md b/docs/models/operations/hrislistshiftsqueryparamfilter.md new file mode 100644 index 00000000..a76022ab --- /dev/null +++ b/docs/models/operations/hrislistshiftsqueryparamfilter.md @@ -0,0 +1,14 @@ +# HrisListShiftsQueryParamFilter + +HRIS Shifts filters + + +## Fields + +| Field | Type | Required | Description | Example | +| -------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------- | +| `employee_id` | *T.nilable(::String)* | :heavy_minus_sign: | Filter to select shifts by employee ID | | +| `ends_before` | [Date](https://ruby-doc.org/stdlib-2.6.1/libdoc/date/rdoc/Date.html) | :heavy_minus_sign: | Filter shifts that end before this date | | +| `starts_after` | [Date](https://ruby-doc.org/stdlib-2.6.1/libdoc/date/rdoc/Date.html) | :heavy_minus_sign: | Filter shifts that start after this date | | +| `status` | [T.nilable(Models::Operations::HrisListShiftsQueryParamStatus)](../../models/operations/hrislistshiftsqueryparamstatus.md) | :heavy_minus_sign: | Filter to select shifts by status | | +| `updated_after` | *T.nilable(::String)* | :heavy_minus_sign: | Use a string with a date to only select results updated after that given date | 2020-01-01T00:00:00.000Z | \ No newline at end of file diff --git a/docs/models/operations/hrislistshiftsqueryparamstatus.md b/docs/models/operations/hrislistshiftsqueryparamstatus.md new file mode 100644 index 00000000..bdca42bd --- /dev/null +++ b/docs/models/operations/hrislistshiftsqueryparamstatus.md @@ -0,0 +1,14 @@ +# HrisListShiftsQueryParamStatus + +Filter to select shifts by status + + +## Values + +| Name | Value | +| ---------------- | ---------------- | +| `DRAFT` | draft | +| `PUBLISHED` | published | +| `CONFIRMED` | confirmed | +| `CANCELLED` | cancelled | +| `UNMAPPED_VALUE` | unmapped_value | \ No newline at end of file diff --git a/docs/models/operations/hrislistshiftsrequest.md b/docs/models/operations/hrislistshiftsrequest.md new file mode 100644 index 00000000..14583194 --- /dev/null +++ b/docs/models/operations/hrislistshiftsrequest.md @@ -0,0 +1,16 @@ +# HrisListShiftsRequest + + +## Fields + +| Field | Type | Required | Description | Example | +| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | +| `fields_` | *T.nilable(::String)* | :heavy_minus_sign: | The comma separated list of fields to return in the response (if empty, all fields are returned) | | +| `filter` | [T.nilable(Models::Operations::HrisListShiftsQueryParamFilter)](../../models/operations/hrislistshiftsqueryparamfilter.md) | :heavy_minus_sign: | HRIS Shifts filters | | +| `next_` | *T.nilable(::String)* | :heavy_minus_sign: | The unified cursor | | +| ~~`page`~~ | *T.nilable(::String)* | :heavy_minus_sign: | : warning: ** DEPRECATED **: This will be removed in a future release, please migrate away from it as soon as possible.

The page number of the results to fetch | | +| `page_size` | *T.nilable(::String)* | :heavy_minus_sign: | The number of results per page (default value is 25) | | +| `proxy` | T::Hash[Symbol, *::Object*] | :heavy_minus_sign: | Query parameters that can be used to pass through parameters to the underlying provider request by surrounding them with 'proxy' key | | +| `raw` | *T.nilable(T::Boolean)* | :heavy_minus_sign: | Indicates that the raw request result should be returned in addition to the mapped result (default value is false) | | +| ~~`updated_after`~~ | *T.nilable(::String)* | :heavy_minus_sign: | : warning: ** DEPRECATED **: This will be removed in a future release, please migrate away from it as soon as possible.

Use a string with a date to only select results updated after that given date | 2020-01-01T00:00:00.000Z | +| `x_account_id` | *::String* | :heavy_check_mark: | The account identifier | | \ No newline at end of file diff --git a/docs/models/operations/hrislistshiftsresponse.md b/docs/models/operations/hrislistshiftsresponse.md new file mode 100644 index 00000000..5d437990 --- /dev/null +++ b/docs/models/operations/hrislistshiftsresponse.md @@ -0,0 +1,12 @@ +# HrisListShiftsResponse + + +## Fields + +| Field | Type | Required | Description | +| -------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------- | +| `content_type` | *::String* | :heavy_check_mark: | HTTP response content type for this operation | +| `headers` | T::Hash[Symbol, T::Array<*::String*>] | :heavy_check_mark: | N/A | +| `hris_shifts_paginated` | [T.nilable(Models::Shared::HrisShiftsPaginated)](../../models/shared/hrisshiftspaginated.md) | :heavy_minus_sign: | The list of shifts was retrieved. | +| `status_code` | *::Integer* | :heavy_check_mark: | HTTP response status code for this operation | +| `raw_response` | [Faraday::Response](https://www.rubydoc.info/gems/faraday/Faraday/Response) | :heavy_check_mark: | Raw HTTP response; suitable for custom response parsing | \ No newline at end of file diff --git a/docs/models/shared/approvalstatus.md b/docs/models/shared/approvalstatus.md new file mode 100644 index 00000000..4ef90b9c --- /dev/null +++ b/docs/models/shared/approvalstatus.md @@ -0,0 +1,11 @@ +# ApprovalStatus + +The approval status of the shift + + +## Fields + +| Field | Type | Required | Description | Example | +| ---------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------- | +| `source_value` | [T.nilable(T.any(::String, ::Float, T::Boolean, Models::Shared::HrisShift4, T::Array[::Object]))](../../models/shared/hrisshiftsourcevalue.md) | :heavy_minus_sign: | N/A | Approved | +| `value` | [T.nilable(Models::Shared::HrisShiftValue)](../../models/shared/hrisshiftvalue.md) | :heavy_minus_sign: | The approval status of the shift | approved | \ No newline at end of file diff --git a/docs/models/shared/data.md b/docs/models/shared/data.md new file mode 100644 index 00000000..7801007a --- /dev/null +++ b/docs/models/shared/data.md @@ -0,0 +1,20 @@ +# Data + + +## Fields + +| Field | Type | Required | Description | Example | +| ---------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------- | +| `approval_status` | [T.nilable(Models::Shared::HrisShiftResultApprovalStatus)](../../models/shared/hrisshiftresultapprovalstatus.md) | :heavy_minus_sign: | The approval status of the shift | | +| `break_duration` | *T.nilable(::String)* | :heavy_minus_sign: | The total break duration for this shift in ISO 8601 duration format | PT1H30M | +| `breaks` | T::Array<[Models::Shared::ShiftBreak](../../models/shared/shiftbreak.md)> | :heavy_minus_sign: | The breaks taken during this shift | | +| `company_id` | *T.nilable(::String)* | :heavy_minus_sign: | The company ID associated with this shift | comp_123456789 | +| `created_at` | [Date](https://ruby-doc.org/stdlib-2.6.1/libdoc/date/rdoc/Date.html) | :heavy_minus_sign: | The date and time the shift was created | 2024-03-20T08:00:00Z | +| `employee_id` | *T.nilable(::String)* | :heavy_minus_sign: | The employee ID associated with this shift | emp_123456789 | +| `end_time` | [Date](https://ruby-doc.org/stdlib-2.6.1/libdoc/date/rdoc/Date.html) | :heavy_minus_sign: | The end time of the shift | 2024-03-20T17:00:00Z | +| `id` | *T.nilable(::String)* | :heavy_minus_sign: | Unique identifier | 8187e5da-dc77-475e-9949-af0f1fa4e4e3 | +| `location_id` | *T.nilable(::String)* | :heavy_minus_sign: | The location ID where this shift takes place | loc_123456789 | +| `remote_id` | *T.nilable(::String)* | :heavy_minus_sign: | Provider's unique identifier | 8187e5da-dc77-475e-9949-af0f1fa4e4e3 | +| `start_time` | [Date](https://ruby-doc.org/stdlib-2.6.1/libdoc/date/rdoc/Date.html) | :heavy_minus_sign: | The start time of the shift | 2024-03-20T09:00:00Z | +| `status` | [T.nilable(Models::Shared::HrisShiftResultStatus)](../../models/shared/hrisshiftresultstatus.md) | :heavy_minus_sign: | The status of the shift | | +| `updated_at` | [Date](https://ruby-doc.org/stdlib-2.6.1/libdoc/date/rdoc/Date.html) | :heavy_minus_sign: | The date and time the shift was last updated | 2024-03-20T08:00:00Z | \ No newline at end of file diff --git a/docs/models/shared/hrisshift.md b/docs/models/shared/hrisshift.md new file mode 100644 index 00000000..09a4f657 --- /dev/null +++ b/docs/models/shared/hrisshift.md @@ -0,0 +1,20 @@ +# HrisShift + + +## Fields + +| Field | Type | Required | Description | Example | +| ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------ | +| `approval_status` | [T.nilable(Models::Shared::ApprovalStatus)](../../models/shared/approvalstatus.md) | :heavy_minus_sign: | The approval status of the shift | | +| `break_duration` | *T.nilable(::String)* | :heavy_minus_sign: | The total break duration for this shift in ISO 8601 duration format | PT1H30M | +| `breaks` | T::Array<[Models::Shared::ShiftBreak](../../models/shared/shiftbreak.md)> | :heavy_minus_sign: | The breaks taken during this shift | | +| `company_id` | *T.nilable(::String)* | :heavy_minus_sign: | The company ID associated with this shift | comp_123456789 | +| `created_at` | [Date](https://ruby-doc.org/stdlib-2.6.1/libdoc/date/rdoc/Date.html) | :heavy_minus_sign: | The date and time the shift was created | 2024-03-20T08:00:00Z | +| `employee_id` | *T.nilable(::String)* | :heavy_minus_sign: | The employee ID associated with this shift | emp_123456789 | +| `end_time` | [Date](https://ruby-doc.org/stdlib-2.6.1/libdoc/date/rdoc/Date.html) | :heavy_minus_sign: | The end time of the shift | 2024-03-20T17:00:00Z | +| `id` | *T.nilable(::String)* | :heavy_minus_sign: | Unique identifier | 8187e5da-dc77-475e-9949-af0f1fa4e4e3 | +| `location_id` | *T.nilable(::String)* | :heavy_minus_sign: | The location ID where this shift takes place | loc_123456789 | +| `remote_id` | *T.nilable(::String)* | :heavy_minus_sign: | Provider's unique identifier | 8187e5da-dc77-475e-9949-af0f1fa4e4e3 | +| `start_time` | [Date](https://ruby-doc.org/stdlib-2.6.1/libdoc/date/rdoc/Date.html) | :heavy_minus_sign: | The start time of the shift | 2024-03-20T09:00:00Z | +| `status` | [T.nilable(Models::Shared::HrisShiftStatus)](../../models/shared/hrisshiftstatus.md) | :heavy_minus_sign: | The status of the shift | | +| `updated_at` | [Date](https://ruby-doc.org/stdlib-2.6.1/libdoc/date/rdoc/Date.html) | :heavy_minus_sign: | The date and time the shift was last updated | 2024-03-20T08:00:00Z | \ No newline at end of file diff --git a/docs/models/shared/hrisshift4.md b/docs/models/shared/hrisshift4.md new file mode 100644 index 00000000..ba127a82 --- /dev/null +++ b/docs/models/shared/hrisshift4.md @@ -0,0 +1,7 @@ +# HrisShift4 + + +## Fields + +| Field | Type | Required | Description | +| ----------- | ----------- | ----------- | ----------- | \ No newline at end of file diff --git a/docs/models/shared/hrisshiftresult.md b/docs/models/shared/hrisshiftresult.md new file mode 100644 index 00000000..cf391cd6 --- /dev/null +++ b/docs/models/shared/hrisshiftresult.md @@ -0,0 +1,9 @@ +# HrisShiftResult + + +## Fields + +| Field | Type | Required | Description | +| --------------------------------------------------------------------------- | --------------------------------------------------------------------------- | --------------------------------------------------------------------------- | --------------------------------------------------------------------------- | +| `data` | [T.nilable(Models::Shared::Data)](../../models/shared/data.md) | :heavy_minus_sign: | N/A | +| `raw` | T::Array<[Models::Shared::RawResponse](../../models/shared/rawresponse.md)> | :heavy_minus_sign: | N/A | \ No newline at end of file diff --git a/docs/models/shared/hrisshiftresult4.md b/docs/models/shared/hrisshiftresult4.md new file mode 100644 index 00000000..1950d274 --- /dev/null +++ b/docs/models/shared/hrisshiftresult4.md @@ -0,0 +1,7 @@ +# HrisShiftResult4 + + +## Fields + +| Field | Type | Required | Description | +| ----------- | ----------- | ----------- | ----------- | \ No newline at end of file diff --git a/docs/models/shared/hrisshiftresultapprovalstatus.md b/docs/models/shared/hrisshiftresultapprovalstatus.md new file mode 100644 index 00000000..b3301479 --- /dev/null +++ b/docs/models/shared/hrisshiftresultapprovalstatus.md @@ -0,0 +1,11 @@ +# HrisShiftResultApprovalStatus + +The approval status of the shift + + +## Fields + +| Field | Type | Required | Description | Example | +| ---------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `source_value` | [T.nilable(T.any(::String, ::Float, T::Boolean, Models::Shared::HrisShiftResult4, T::Array[::Object]))](../../models/shared/hrisshiftresultsourcevalue.md) | :heavy_minus_sign: | N/A | Approved | +| `value` | [T.nilable(Models::Shared::HrisShiftResultValue)](../../models/shared/hrisshiftresultvalue.md) | :heavy_minus_sign: | The approval status of the shift | approved | \ No newline at end of file diff --git a/docs/models/shared/hrisshiftresultschemas4.md b/docs/models/shared/hrisshiftresultschemas4.md new file mode 100644 index 00000000..271a68a0 --- /dev/null +++ b/docs/models/shared/hrisshiftresultschemas4.md @@ -0,0 +1,7 @@ +# HrisShiftResultSchemas4 + + +## Fields + +| Field | Type | Required | Description | +| ----------- | ----------- | ----------- | ----------- | \ No newline at end of file diff --git a/docs/models/shared/hrisshiftresultschemassourcevalue.md b/docs/models/shared/hrisshiftresultschemassourcevalue.md new file mode 100644 index 00000000..f7951e87 --- /dev/null +++ b/docs/models/shared/hrisshiftresultschemassourcevalue.md @@ -0,0 +1,2 @@ +# HrisShiftResultSchemasSourceValue + diff --git a/docs/models/shared/hrisshiftresultschemasvalue.md b/docs/models/shared/hrisshiftresultschemasvalue.md new file mode 100644 index 00000000..c632adf2 --- /dev/null +++ b/docs/models/shared/hrisshiftresultschemasvalue.md @@ -0,0 +1,14 @@ +# HrisShiftResultSchemasValue + +The status of the shift + + +## Values + +| Name | Value | +| ---------------- | ---------------- | +| `DRAFT` | draft | +| `PUBLISHED` | published | +| `CONFIRMED` | confirmed | +| `CANCELLED` | cancelled | +| `UNMAPPED_VALUE` | unmapped_value | \ No newline at end of file diff --git a/docs/models/shared/hrisshiftresultsourcevalue.md b/docs/models/shared/hrisshiftresultsourcevalue.md new file mode 100644 index 00000000..31a48cf3 --- /dev/null +++ b/docs/models/shared/hrisshiftresultsourcevalue.md @@ -0,0 +1,2 @@ +# HrisShiftResultSourceValue + diff --git a/docs/models/shared/hrisshiftresultstatus.md b/docs/models/shared/hrisshiftresultstatus.md new file mode 100644 index 00000000..9515e6bf --- /dev/null +++ b/docs/models/shared/hrisshiftresultstatus.md @@ -0,0 +1,11 @@ +# HrisShiftResultStatus + +The status of the shift + + +## Fields + +| Field | Type | Required | Description | Example | +| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | +| `source_value` | [T.nilable(T.any(::String, ::Float, T::Boolean, Models::Shared::HrisShiftResultSchemas4, T::Array[::Object]))](../../models/shared/hrisshiftresultschemassourcevalue.md) | :heavy_minus_sign: | N/A | Confirmed | +| `value` | [T.nilable(Models::Shared::HrisShiftResultSchemasValue)](../../models/shared/hrisshiftresultschemasvalue.md) | :heavy_minus_sign: | The status of the shift | confirmed | \ No newline at end of file diff --git a/docs/models/shared/hrisshiftresultvalue.md b/docs/models/shared/hrisshiftresultvalue.md new file mode 100644 index 00000000..451c9cdb --- /dev/null +++ b/docs/models/shared/hrisshiftresultvalue.md @@ -0,0 +1,13 @@ +# HrisShiftResultValue + +The approval status of the shift + + +## Values + +| Name | Value | +| ---------------- | ---------------- | +| `PENDING` | pending | +| `APPROVED` | approved | +| `REJECTED` | rejected | +| `UNMAPPED_VALUE` | unmapped_value | \ No newline at end of file diff --git a/docs/models/shared/hrisshiftschemas4.md b/docs/models/shared/hrisshiftschemas4.md new file mode 100644 index 00000000..cb24e988 --- /dev/null +++ b/docs/models/shared/hrisshiftschemas4.md @@ -0,0 +1,7 @@ +# HrisShiftSchemas4 + + +## Fields + +| Field | Type | Required | Description | +| ----------- | ----------- | ----------- | ----------- | \ No newline at end of file diff --git a/docs/models/shared/hrisshiftschemassourcevalue.md b/docs/models/shared/hrisshiftschemassourcevalue.md new file mode 100644 index 00000000..a7bb8caa --- /dev/null +++ b/docs/models/shared/hrisshiftschemassourcevalue.md @@ -0,0 +1,2 @@ +# HrisShiftSchemasSourceValue + diff --git a/docs/models/shared/hrisshiftschemasvalue.md b/docs/models/shared/hrisshiftschemasvalue.md new file mode 100644 index 00000000..52bbf901 --- /dev/null +++ b/docs/models/shared/hrisshiftschemasvalue.md @@ -0,0 +1,14 @@ +# HrisShiftSchemasValue + +The status of the shift + + +## Values + +| Name | Value | +| ---------------- | ---------------- | +| `DRAFT` | draft | +| `PUBLISHED` | published | +| `CONFIRMED` | confirmed | +| `CANCELLED` | cancelled | +| `UNMAPPED_VALUE` | unmapped_value | \ No newline at end of file diff --git a/docs/models/shared/hrisshiftsourcevalue.md b/docs/models/shared/hrisshiftsourcevalue.md new file mode 100644 index 00000000..462f22fa --- /dev/null +++ b/docs/models/shared/hrisshiftsourcevalue.md @@ -0,0 +1,2 @@ +# HrisShiftSourceValue + diff --git a/docs/models/shared/hrisshiftspaginated.md b/docs/models/shared/hrisshiftspaginated.md new file mode 100644 index 00000000..2ced405c --- /dev/null +++ b/docs/models/shared/hrisshiftspaginated.md @@ -0,0 +1,10 @@ +# HrisShiftsPaginated + + +## Fields + +| Field | Type | Required | Description | +| --------------------------------------------------------------------------- | --------------------------------------------------------------------------- | --------------------------------------------------------------------------- | --------------------------------------------------------------------------- | +| `data` | T::Array<[Models::Shared::HrisShift](../../models/shared/hrisshift.md)> | :heavy_minus_sign: | N/A | +| `next_` | *T.nilable(::String)* | :heavy_minus_sign: | N/A | +| `raw` | T::Array<[Models::Shared::RawResponse](../../models/shared/rawresponse.md)> | :heavy_minus_sign: | N/A | \ No newline at end of file diff --git a/docs/models/shared/hrisshiftstatus.md b/docs/models/shared/hrisshiftstatus.md new file mode 100644 index 00000000..be4a61f7 --- /dev/null +++ b/docs/models/shared/hrisshiftstatus.md @@ -0,0 +1,11 @@ +# HrisShiftStatus + +The status of the shift + + +## Fields + +| Field | Type | Required | Description | Example | +| ------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------ | +| `source_value` | [T.nilable(T.any(::String, ::Float, T::Boolean, Models::Shared::HrisShiftSchemas4, T::Array[::Object]))](../../models/shared/hrisshiftschemassourcevalue.md) | :heavy_minus_sign: | N/A | Confirmed | +| `value` | [T.nilable(Models::Shared::HrisShiftSchemasValue)](../../models/shared/hrisshiftschemasvalue.md) | :heavy_minus_sign: | The status of the shift | confirmed | \ No newline at end of file diff --git a/docs/models/shared/hrisshiftvalue.md b/docs/models/shared/hrisshiftvalue.md new file mode 100644 index 00000000..345a8218 --- /dev/null +++ b/docs/models/shared/hrisshiftvalue.md @@ -0,0 +1,13 @@ +# HrisShiftValue + +The approval status of the shift + + +## Values + +| Name | Value | +| ---------------- | ---------------- | +| `PENDING` | pending | +| `APPROVED` | approved | +| `REJECTED` | rejected | +| `UNMAPPED_VALUE` | unmapped_value | \ No newline at end of file diff --git a/docs/models/shared/shiftbreak.md b/docs/models/shared/shiftbreak.md new file mode 100644 index 00000000..bb3412fe --- /dev/null +++ b/docs/models/shared/shiftbreak.md @@ -0,0 +1,14 @@ +# ShiftBreak + + +## Fields + +| Field | Type | Required | Description | Example | +| -------------------------------------------------------------------- | -------------------------------------------------------------------- | -------------------------------------------------------------------- | -------------------------------------------------------------------- | -------------------------------------------------------------------- | +| `created_at` | [Date](https://ruby-doc.org/stdlib-2.6.1/libdoc/date/rdoc/Date.html) | :heavy_minus_sign: | The date and time the break was created | 2024-03-20T10:00:00Z | +| `duration` | *T.nilable(::String)* | :heavy_minus_sign: | The duration of the break in ISO 8601 duration format | PT1H | +| `end_time` | [Date](https://ruby-doc.org/stdlib-2.6.1/libdoc/date/rdoc/Date.html) | :heavy_minus_sign: | The end time of the break | 2024-03-20T13:00:00Z | +| `id` | *T.nilable(::String)* | :heavy_minus_sign: | The unique identifier of the break | break_123456789 | +| `is_paid` | *T.nilable(T::Boolean)* | :heavy_minus_sign: | Whether the break is paid | true | +| `start_time` | [Date](https://ruby-doc.org/stdlib-2.6.1/libdoc/date/rdoc/Date.html) | :heavy_minus_sign: | The start time of the break | 2024-03-20T12:00:00Z | +| `updated_at` | [Date](https://ruby-doc.org/stdlib-2.6.1/libdoc/date/rdoc/Date.html) | :heavy_minus_sign: | The date and time the break was last updated | 2024-03-20T10:00:00Z | \ No newline at end of file diff --git a/docs/sdks/ats/README.md b/docs/sdks/ats/README.md index 15825b0c..44ed8858 100644 --- a/docs/sdks/ats/README.md +++ b/docs/sdks/ats/README.md @@ -17,6 +17,7 @@ * [get_application](#get_application) - Get Application * [get_application_custom_field_definition](#get_application_custom_field_definition) - Get Application Custom Field Definition * [get_application_document](#get_application_document) - Get Application Document +* [get_application_document_category](#get_application_document_category) - Get Application Document Category * [get_application_note](#get_application_note) - Get Application Note * [get_application_offer](#get_application_offer) - Get Application Offer * [get_application_scheduled_interview](#get_application_scheduled_interview) - Get Applications scheduled interview @@ -41,6 +42,7 @@ * [get_user](#get_user) - Get User * [list_application_changes](#list_application_changes) - List Application Changes * [list_application_custom_field_definitions](#list_application_custom_field_definitions) - List Application Custom Field Definitions +* [list_application_document_categories](#list_application_document_categories) - List Application Document Categories * [list_application_documents](#list_application_documents) - List Application Documents * [list_application_notes](#list_application_notes) - List Application Notes * [list_application_scorecards](#list_application_scorecards) - List Application Scorecards @@ -782,6 +784,48 @@ end +## get_application_document_category + +Get Application Document Category + +### Example Usage + +```ruby +require 'stackone_client' + +s = ::StackOne::StackOne.new( + security: Models::Shared::Security.new( + password: "", + username: "", + ), + ) + +req = Models::Operations::AtsGetApplicationDocumentCategoryRequest.new( + fields_: "id,remote_id,name,active", + id: "", + x_account_id: "", +) + +res = s.ats.get_application_document_category(req) + +if ! res.reference_result.nil? + # handle response +end + +``` + +### Parameters + +| Parameter | Type | Required | Description | +| ----------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------- | +| `request` | [Models::Operations::AtsGetApplicationDocumentCategoryRequest](../../models/operations/atsgetapplicationdocumentcategoryrequest.md) | :heavy_check_mark: | The request object to use for the request. | + +### Response + +**[T.nilable(Models::Operations::AtsGetApplicationDocumentCategoryResponse)](../../models/operations/atsgetapplicationdocumentcategoryresponse.md)** + + + ## get_application_note Get Application Note @@ -1809,6 +1853,50 @@ end +## list_application_document_categories + +List Application Document Categories + +### Example Usage + +```ruby +require 'stackone_client' + +s = ::StackOne::StackOne.new( + security: Models::Shared::Security.new( + password: "", + username: "", + ), + ) + +req = Models::Operations::AtsListApplicationDocumentCategoriesRequest.new( + fields_: "id,remote_id,name,active", + filter: Models::Operations::AtsListApplicationDocumentCategoriesQueryParamFilter.new( + updated_after: "2020-01-01T00:00:00.000Z", + ), + x_account_id: "", +) + +res = s.ats.list_application_document_categories(req) + +if ! res.reference_paginated.nil? + # handle response +end + +``` + +### Parameters + +| Parameter | Type | Required | Description | +| ----------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------- | +| `request` | [Models::Operations::AtsListApplicationDocumentCategoriesRequest](../../models/operations/atslistapplicationdocumentcategoriesrequest.md) | :heavy_check_mark: | The request object to use for the request. | + +### Response + +**[T.nilable(Models::Operations::AtsListApplicationDocumentCategoriesResponse)](../../models/operations/atslistapplicationdocumentcategoriesresponse.md)** + + + ## list_application_documents List Application Documents diff --git a/docs/sdks/hris/README.md b/docs/sdks/hris/README.md index be03d228..d6dc7e4c 100644 --- a/docs/sdks/hris/README.md +++ b/docs/sdks/hris/README.md @@ -34,6 +34,7 @@ * [get_job](#get_job) - Get Job * [get_location](#get_location) - Get Work Location * [get_position](#get_position) - Get Position +* [get_shift](#get_shift) - Get Shift * [get_task](#get_task) - Get Task * [get_team_group](#get_team_group) - Get Team Group * [get_time_entries](#get_time_entries) - Get Time Entry @@ -63,6 +64,7 @@ * [list_jobs](#list_jobs) - List Jobs * [list_locations](#list_locations) - List Work Locations * [list_positions](#list_positions) - List Positions +* [list_shifts](#list_shifts) - List Shifts * [list_tasks](#list_tasks) - List Tasks * [list_team_groups](#list_team_groups) - List Team Groups * [list_time_entries](#list_time_entries) - List Time Entries @@ -1514,6 +1516,47 @@ end +## get_shift + +Get Shift + +### Example Usage + +```ruby +require 'stackone_client' + +s = ::StackOne::StackOne.new( + security: Models::Shared::Security.new( + password: "", + username: "", + ), + ) + +req = Models::Operations::HrisGetShiftRequest.new( + id: "", + x_account_id: "", +) + +res = s.hris.get_shift(req) + +if ! res.hris_shift_result.nil? + # handle response +end + +``` + +### Parameters + +| Parameter | Type | Required | Description | +| ----------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------- | +| `request` | [Models::Operations::HrisGetShiftRequest](../../models/operations/hrisgetshiftrequest.md) | :heavy_check_mark: | The request object to use for the request. | + +### Response + +**[T.nilable(Models::Operations::HrisGetShiftResponse)](../../models/operations/hrisgetshiftresponse.md)** + + + ## get_task Get Task @@ -2795,6 +2838,49 @@ end +## list_shifts + +List Shifts + +### Example Usage + +```ruby +require 'stackone_client' + +s = ::StackOne::StackOne.new( + security: Models::Shared::Security.new( + password: "", + username: "", + ), + ) + +req = Models::Operations::HrisListShiftsRequest.new( + filter: Models::Operations::HrisListShiftsQueryParamFilter.new( + updated_after: "2020-01-01T00:00:00.000Z", + ), + x_account_id: "", +) + +res = s.hris.list_shifts(req) + +if ! res.hris_shifts_paginated.nil? + # handle response +end + +``` + +### Parameters + +| Parameter | Type | Required | Description | +| --------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------- | +| `request` | [Models::Operations::HrisListShiftsRequest](../../models/operations/hrislistshiftsrequest.md) | :heavy_check_mark: | The request object to use for the request. | + +### Response + +**[T.nilable(Models::Operations::HrisListShiftsResponse)](../../models/operations/hrislistshiftsresponse.md)** + + + ## list_tasks List Tasks diff --git a/gen.yaml b/gen.yaml index 809e335f..1f4703cd 100644 --- a/gen.yaml +++ b/gen.yaml @@ -15,7 +15,7 @@ generation: oAuth2ClientCredentialsEnabled: false oAuth2PasswordEnabled: false ruby: - version: 0.27.0 + version: 0.29.0 additionalDependencies: development: {} runtime: {} diff --git a/lib/stack_one/ats.rb b/lib/stack_one/ats.rb index 2b54a65e..266e3a2a 100644 --- a/lib/stack_one/ats.rb +++ b/lib/stack_one/ats.rb @@ -3418,19 +3418,19 @@ def get_application_document(request, retries = nil, timeout_ms = nil) end - sig { params(request: T.nilable(Models::Operations::AtsGetApplicationNoteRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::AtsGetApplicationNoteResponse) } - def get_application_note(request, retries = nil, timeout_ms = nil) - # get_application_note - Get Application Note + sig { params(request: T.nilable(Models::Operations::AtsGetApplicationDocumentCategoryRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::AtsGetApplicationDocumentCategoryResponse) } + def get_application_document_category(request, retries = nil, timeout_ms = nil) + # get_application_document_category - Get Application Document Category url, params = @sdk_configuration.get_server_details base_url = Utils.template_url(url, params) url = Utils.generate_url( - Models::Operations::AtsGetApplicationNoteRequest, + Models::Operations::AtsGetApplicationDocumentCategoryRequest, base_url, - '/unified/ats/applications/{id}/notes/{subResourceId}', + '/unified/ats/documents/application_categories/{id}', request ) headers = Utils.get_headers(request) - query_params = Utils.get_query_params(Models::Operations::AtsGetApplicationNoteRequest, request) + query_params = Utils.get_query_params(Models::Operations::AtsGetApplicationDocumentCategoryRequest, request) headers['Accept'] = 'application/json' headers['user-agent'] = @sdk_configuration.user_agent retries ||= @sdk_configuration.retry_config @@ -3458,7 +3458,7 @@ def get_application_note(request, retries = nil, timeout_ms = nil) hook_ctx = SDKHooks::HookContext.new( base_url: base_url, oauth2_scopes: [], - operation_id: 'ats_get_application_note', + operation_id: 'ats_get_application_document_category', security_source: @sdk_configuration.security_source ) @@ -3515,12 +3515,12 @@ def get_application_note(request, retries = nil, timeout_ms = nil) ), response: http_response ) - obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::NoteResult) - response = Models::Operations::AtsGetApplicationNoteResponse.new( + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::ReferenceResult) + response = Models::Operations::AtsGetApplicationDocumentCategoryResponse.new( status_code: http_response.status, content_type: content_type, raw_response: http_response, - note_result: obj + reference_result: obj ) return response @@ -3694,19 +3694,19 @@ def get_application_note(request, retries = nil, timeout_ms = nil) end - sig { params(request: T.nilable(Models::Operations::AtsGetApplicationOfferRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::AtsGetApplicationOfferResponse) } - def get_application_offer(request, retries = nil, timeout_ms = nil) - # get_application_offer - Get Application Offer + sig { params(request: T.nilable(Models::Operations::AtsGetApplicationNoteRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::AtsGetApplicationNoteResponse) } + def get_application_note(request, retries = nil, timeout_ms = nil) + # get_application_note - Get Application Note url, params = @sdk_configuration.get_server_details base_url = Utils.template_url(url, params) url = Utils.generate_url( - Models::Operations::AtsGetApplicationOfferRequest, + Models::Operations::AtsGetApplicationNoteRequest, base_url, - '/unified/ats/applications/{id}/offers/{subResourceId}', + '/unified/ats/applications/{id}/notes/{subResourceId}', request ) headers = Utils.get_headers(request) - query_params = Utils.get_query_params(Models::Operations::AtsGetApplicationOfferRequest, request) + query_params = Utils.get_query_params(Models::Operations::AtsGetApplicationNoteRequest, request) headers['Accept'] = 'application/json' headers['user-agent'] = @sdk_configuration.user_agent retries ||= @sdk_configuration.retry_config @@ -3734,7 +3734,7 @@ def get_application_offer(request, retries = nil, timeout_ms = nil) hook_ctx = SDKHooks::HookContext.new( base_url: base_url, oauth2_scopes: [], - operation_id: 'ats_get_application_offer', + operation_id: 'ats_get_application_note', security_source: @sdk_configuration.security_source ) @@ -3791,12 +3791,12 @@ def get_application_offer(request, retries = nil, timeout_ms = nil) ), response: http_response ) - obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::OffersResult) - response = Models::Operations::AtsGetApplicationOfferResponse.new( + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::NoteResult) + response = Models::Operations::AtsGetApplicationNoteResponse.new( status_code: http_response.status, content_type: content_type, raw_response: http_response, - offers_result: obj + note_result: obj ) return response @@ -3970,19 +3970,19 @@ def get_application_offer(request, retries = nil, timeout_ms = nil) end - sig { params(request: T.nilable(Models::Operations::AtsGetApplicationScheduledInterviewRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::AtsGetApplicationScheduledInterviewResponse) } - def get_application_scheduled_interview(request, retries = nil, timeout_ms = nil) - # get_application_scheduled_interview - Get Applications scheduled interview + sig { params(request: T.nilable(Models::Operations::AtsGetApplicationOfferRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::AtsGetApplicationOfferResponse) } + def get_application_offer(request, retries = nil, timeout_ms = nil) + # get_application_offer - Get Application Offer url, params = @sdk_configuration.get_server_details base_url = Utils.template_url(url, params) url = Utils.generate_url( - Models::Operations::AtsGetApplicationScheduledInterviewRequest, + Models::Operations::AtsGetApplicationOfferRequest, base_url, - '/unified/ats/applications/{id}/scheduled_interviews/{subResourceId}', + '/unified/ats/applications/{id}/offers/{subResourceId}', request ) headers = Utils.get_headers(request) - query_params = Utils.get_query_params(Models::Operations::AtsGetApplicationScheduledInterviewRequest, request) + query_params = Utils.get_query_params(Models::Operations::AtsGetApplicationOfferRequest, request) headers['Accept'] = 'application/json' headers['user-agent'] = @sdk_configuration.user_agent retries ||= @sdk_configuration.retry_config @@ -4010,7 +4010,7 @@ def get_application_scheduled_interview(request, retries = nil, timeout_ms = nil hook_ctx = SDKHooks::HookContext.new( base_url: base_url, oauth2_scopes: [], - operation_id: 'ats_get_application_scheduled_interview', + operation_id: 'ats_get_application_offer', security_source: @sdk_configuration.security_source ) @@ -4067,12 +4067,12 @@ def get_application_scheduled_interview(request, retries = nil, timeout_ms = nil ), response: http_response ) - obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::ScheduledInterviewsResult) - response = Models::Operations::AtsGetApplicationScheduledInterviewResponse.new( + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::OffersResult) + response = Models::Operations::AtsGetApplicationOfferResponse.new( status_code: http_response.status, content_type: content_type, raw_response: http_response, - scheduled_interviews_result: obj + offers_result: obj ) return response @@ -4246,19 +4246,19 @@ def get_application_scheduled_interview(request, retries = nil, timeout_ms = nil end - sig { params(request: T.nilable(Models::Operations::AtsGetApplicationScorecardRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::AtsGetApplicationScorecardResponse) } - def get_application_scorecard(request, retries = nil, timeout_ms = nil) - # get_application_scorecard - Get Application Scorecard + sig { params(request: T.nilable(Models::Operations::AtsGetApplicationScheduledInterviewRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::AtsGetApplicationScheduledInterviewResponse) } + def get_application_scheduled_interview(request, retries = nil, timeout_ms = nil) + # get_application_scheduled_interview - Get Applications scheduled interview url, params = @sdk_configuration.get_server_details base_url = Utils.template_url(url, params) url = Utils.generate_url( - Models::Operations::AtsGetApplicationScorecardRequest, + Models::Operations::AtsGetApplicationScheduledInterviewRequest, base_url, - '/unified/ats/applications/{id}/scorecards/{subResourceId}', + '/unified/ats/applications/{id}/scheduled_interviews/{subResourceId}', request ) headers = Utils.get_headers(request) - query_params = Utils.get_query_params(Models::Operations::AtsGetApplicationScorecardRequest, request) + query_params = Utils.get_query_params(Models::Operations::AtsGetApplicationScheduledInterviewRequest, request) headers['Accept'] = 'application/json' headers['user-agent'] = @sdk_configuration.user_agent retries ||= @sdk_configuration.retry_config @@ -4286,7 +4286,7 @@ def get_application_scorecard(request, retries = nil, timeout_ms = nil) hook_ctx = SDKHooks::HookContext.new( base_url: base_url, oauth2_scopes: [], - operation_id: 'ats_get_application_scorecard', + operation_id: 'ats_get_application_scheduled_interview', security_source: @sdk_configuration.security_source ) @@ -4343,12 +4343,12 @@ def get_application_scorecard(request, retries = nil, timeout_ms = nil) ), response: http_response ) - obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::ScorecardsResult) - response = Models::Operations::AtsGetApplicationScorecardResponse.new( + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::ScheduledInterviewsResult) + response = Models::Operations::AtsGetApplicationScheduledInterviewResponse.new( status_code: http_response.status, content_type: content_type, raw_response: http_response, - scorecards_result: obj + scheduled_interviews_result: obj ) return response @@ -4522,19 +4522,19 @@ def get_application_scorecard(request, retries = nil, timeout_ms = nil) end - sig { params(request: T.nilable(Models::Operations::AtsGetAssessmentsPackageRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::AtsGetAssessmentsPackageResponse) } - def get_assessments_package(request, retries = nil, timeout_ms = nil) - # get_assessments_package - Get Assessments Package + sig { params(request: T.nilable(Models::Operations::AtsGetApplicationScorecardRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::AtsGetApplicationScorecardResponse) } + def get_application_scorecard(request, retries = nil, timeout_ms = nil) + # get_application_scorecard - Get Application Scorecard url, params = @sdk_configuration.get_server_details base_url = Utils.template_url(url, params) url = Utils.generate_url( - Models::Operations::AtsGetAssessmentsPackageRequest, + Models::Operations::AtsGetApplicationScorecardRequest, base_url, - '/unified/ats/assessments/packages/{id}', + '/unified/ats/applications/{id}/scorecards/{subResourceId}', request ) headers = Utils.get_headers(request) - query_params = Utils.get_query_params(Models::Operations::AtsGetAssessmentsPackageRequest, request) + query_params = Utils.get_query_params(Models::Operations::AtsGetApplicationScorecardRequest, request) headers['Accept'] = 'application/json' headers['user-agent'] = @sdk_configuration.user_agent retries ||= @sdk_configuration.retry_config @@ -4562,7 +4562,7 @@ def get_assessments_package(request, retries = nil, timeout_ms = nil) hook_ctx = SDKHooks::HookContext.new( base_url: base_url, oauth2_scopes: [], - operation_id: 'ats_get_assessments_package', + operation_id: 'ats_get_application_scorecard', security_source: @sdk_configuration.security_source ) @@ -4619,12 +4619,12 @@ def get_assessments_package(request, retries = nil, timeout_ms = nil) ), response: http_response ) - obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::AssessmentPackageResult) - response = Models::Operations::AtsGetAssessmentsPackageResponse.new( + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::ScorecardsResult) + response = Models::Operations::AtsGetApplicationScorecardResponse.new( status_code: http_response.status, content_type: content_type, raw_response: http_response, - assessment_package_result: obj + scorecards_result: obj ) return response @@ -4798,19 +4798,19 @@ def get_assessments_package(request, retries = nil, timeout_ms = nil) end - sig { params(request: T.nilable(Models::Operations::AtsGetAssessmentsResultRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::AtsGetAssessmentsResultResponse) } - def get_assessments_result(request, retries = nil, timeout_ms = nil) - # get_assessments_result - Get Assessments Results + sig { params(request: T.nilable(Models::Operations::AtsGetAssessmentsPackageRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::AtsGetAssessmentsPackageResponse) } + def get_assessments_package(request, retries = nil, timeout_ms = nil) + # get_assessments_package - Get Assessments Package url, params = @sdk_configuration.get_server_details base_url = Utils.template_url(url, params) url = Utils.generate_url( - Models::Operations::AtsGetAssessmentsResultRequest, + Models::Operations::AtsGetAssessmentsPackageRequest, base_url, - '/unified/ats/assessments/orders/{id}/results', + '/unified/ats/assessments/packages/{id}', request ) headers = Utils.get_headers(request) - query_params = Utils.get_query_params(Models::Operations::AtsGetAssessmentsResultRequest, request) + query_params = Utils.get_query_params(Models::Operations::AtsGetAssessmentsPackageRequest, request) headers['Accept'] = 'application/json' headers['user-agent'] = @sdk_configuration.user_agent retries ||= @sdk_configuration.retry_config @@ -4838,7 +4838,7 @@ def get_assessments_result(request, retries = nil, timeout_ms = nil) hook_ctx = SDKHooks::HookContext.new( base_url: base_url, oauth2_scopes: [], - operation_id: 'ats_get_assessments_result', + operation_id: 'ats_get_assessments_package', security_source: @sdk_configuration.security_source ) @@ -4895,12 +4895,12 @@ def get_assessments_result(request, retries = nil, timeout_ms = nil) ), response: http_response ) - obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::AssessmentResultsResult) - response = Models::Operations::AtsGetAssessmentsResultResponse.new( + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::AssessmentPackageResult) + response = Models::Operations::AtsGetAssessmentsPackageResponse.new( status_code: http_response.status, content_type: content_type, raw_response: http_response, - assessment_results_result: obj + assessment_package_result: obj ) return response @@ -5074,19 +5074,19 @@ def get_assessments_result(request, retries = nil, timeout_ms = nil) end - sig { params(request: T.nilable(Models::Operations::AtsGetBackgroundCheckPackageRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::AtsGetBackgroundCheckPackageResponse) } - def get_background_check_package(request, retries = nil, timeout_ms = nil) - # get_background_check_package - Get Background Check Package + sig { params(request: T.nilable(Models::Operations::AtsGetAssessmentsResultRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::AtsGetAssessmentsResultResponse) } + def get_assessments_result(request, retries = nil, timeout_ms = nil) + # get_assessments_result - Get Assessments Results url, params = @sdk_configuration.get_server_details base_url = Utils.template_url(url, params) url = Utils.generate_url( - Models::Operations::AtsGetBackgroundCheckPackageRequest, + Models::Operations::AtsGetAssessmentsResultRequest, base_url, - '/unified/ats/background_checks/packages/{id}', + '/unified/ats/assessments/orders/{id}/results', request ) headers = Utils.get_headers(request) - query_params = Utils.get_query_params(Models::Operations::AtsGetBackgroundCheckPackageRequest, request) + query_params = Utils.get_query_params(Models::Operations::AtsGetAssessmentsResultRequest, request) headers['Accept'] = 'application/json' headers['user-agent'] = @sdk_configuration.user_agent retries ||= @sdk_configuration.retry_config @@ -5114,7 +5114,7 @@ def get_background_check_package(request, retries = nil, timeout_ms = nil) hook_ctx = SDKHooks::HookContext.new( base_url: base_url, oauth2_scopes: [], - operation_id: 'ats_get_background_check_package', + operation_id: 'ats_get_assessments_result', security_source: @sdk_configuration.security_source ) @@ -5171,12 +5171,12 @@ def get_background_check_package(request, retries = nil, timeout_ms = nil) ), response: http_response ) - obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::BackgroundCheckPackageResult) - response = Models::Operations::AtsGetBackgroundCheckPackageResponse.new( + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::AssessmentResultsResult) + response = Models::Operations::AtsGetAssessmentsResultResponse.new( status_code: http_response.status, content_type: content_type, raw_response: http_response, - background_check_package_result: obj + assessment_results_result: obj ) return response @@ -5350,19 +5350,19 @@ def get_background_check_package(request, retries = nil, timeout_ms = nil) end - sig { params(request: T.nilable(Models::Operations::AtsGetBackgroundCheckResultRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::AtsGetBackgroundCheckResultResponse) } - def get_background_check_result(request, retries = nil, timeout_ms = nil) - # get_background_check_result - Get Background Check Results + sig { params(request: T.nilable(Models::Operations::AtsGetBackgroundCheckPackageRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::AtsGetBackgroundCheckPackageResponse) } + def get_background_check_package(request, retries = nil, timeout_ms = nil) + # get_background_check_package - Get Background Check Package url, params = @sdk_configuration.get_server_details base_url = Utils.template_url(url, params) url = Utils.generate_url( - Models::Operations::AtsGetBackgroundCheckResultRequest, + Models::Operations::AtsGetBackgroundCheckPackageRequest, base_url, - '/unified/ats/background_checks/orders/{id}/results', + '/unified/ats/background_checks/packages/{id}', request ) headers = Utils.get_headers(request) - query_params = Utils.get_query_params(Models::Operations::AtsGetBackgroundCheckResultRequest, request) + query_params = Utils.get_query_params(Models::Operations::AtsGetBackgroundCheckPackageRequest, request) headers['Accept'] = 'application/json' headers['user-agent'] = @sdk_configuration.user_agent retries ||= @sdk_configuration.retry_config @@ -5390,7 +5390,7 @@ def get_background_check_result(request, retries = nil, timeout_ms = nil) hook_ctx = SDKHooks::HookContext.new( base_url: base_url, oauth2_scopes: [], - operation_id: 'ats_get_background_check_result', + operation_id: 'ats_get_background_check_package', security_source: @sdk_configuration.security_source ) @@ -5447,12 +5447,12 @@ def get_background_check_result(request, retries = nil, timeout_ms = nil) ), response: http_response ) - obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::BackgroundCheckResultsResult) - response = Models::Operations::AtsGetBackgroundCheckResultResponse.new( + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::BackgroundCheckPackageResult) + response = Models::Operations::AtsGetBackgroundCheckPackageResponse.new( status_code: http_response.status, content_type: content_type, raw_response: http_response, - background_check_results_result: obj + background_check_package_result: obj ) return response @@ -5626,19 +5626,19 @@ def get_background_check_result(request, retries = nil, timeout_ms = nil) end - sig { params(request: T.nilable(Models::Operations::AtsGetCandidateRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::AtsGetCandidateResponse) } - def get_candidate(request, retries = nil, timeout_ms = nil) - # get_candidate - Get Candidate + sig { params(request: T.nilable(Models::Operations::AtsGetBackgroundCheckResultRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::AtsGetBackgroundCheckResultResponse) } + def get_background_check_result(request, retries = nil, timeout_ms = nil) + # get_background_check_result - Get Background Check Results url, params = @sdk_configuration.get_server_details base_url = Utils.template_url(url, params) url = Utils.generate_url( - Models::Operations::AtsGetCandidateRequest, + Models::Operations::AtsGetBackgroundCheckResultRequest, base_url, - '/unified/ats/candidates/{id}', + '/unified/ats/background_checks/orders/{id}/results', request ) headers = Utils.get_headers(request) - query_params = Utils.get_query_params(Models::Operations::AtsGetCandidateRequest, request) + query_params = Utils.get_query_params(Models::Operations::AtsGetBackgroundCheckResultRequest, request) headers['Accept'] = 'application/json' headers['user-agent'] = @sdk_configuration.user_agent retries ||= @sdk_configuration.retry_config @@ -5666,7 +5666,7 @@ def get_candidate(request, retries = nil, timeout_ms = nil) hook_ctx = SDKHooks::HookContext.new( base_url: base_url, oauth2_scopes: [], - operation_id: 'ats_get_candidate', + operation_id: 'ats_get_background_check_result', security_source: @sdk_configuration.security_source ) @@ -5723,12 +5723,12 @@ def get_candidate(request, retries = nil, timeout_ms = nil) ), response: http_response ) - obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::CandidateResult) - response = Models::Operations::AtsGetCandidateResponse.new( + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::BackgroundCheckResultsResult) + response = Models::Operations::AtsGetBackgroundCheckResultResponse.new( status_code: http_response.status, content_type: content_type, raw_response: http_response, - candidate_result: obj + background_check_results_result: obj ) return response @@ -5902,19 +5902,19 @@ def get_candidate(request, retries = nil, timeout_ms = nil) end - sig { params(request: T.nilable(Models::Operations::AtsGetCandidateCustomFieldDefinitionRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::AtsGetCandidateCustomFieldDefinitionResponse) } - def get_candidate_custom_field_definition(request, retries = nil, timeout_ms = nil) - # get_candidate_custom_field_definition - Get Candidate Custom Field Definition + sig { params(request: T.nilable(Models::Operations::AtsGetCandidateRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::AtsGetCandidateResponse) } + def get_candidate(request, retries = nil, timeout_ms = nil) + # get_candidate - Get Candidate url, params = @sdk_configuration.get_server_details base_url = Utils.template_url(url, params) url = Utils.generate_url( - Models::Operations::AtsGetCandidateCustomFieldDefinitionRequest, + Models::Operations::AtsGetCandidateRequest, base_url, - '/unified/ats/custom_field_definitions/candidates/{id}', + '/unified/ats/candidates/{id}', request ) headers = Utils.get_headers(request) - query_params = Utils.get_query_params(Models::Operations::AtsGetCandidateCustomFieldDefinitionRequest, request) + query_params = Utils.get_query_params(Models::Operations::AtsGetCandidateRequest, request) headers['Accept'] = 'application/json' headers['user-agent'] = @sdk_configuration.user_agent retries ||= @sdk_configuration.retry_config @@ -5942,7 +5942,7 @@ def get_candidate_custom_field_definition(request, retries = nil, timeout_ms = n hook_ctx = SDKHooks::HookContext.new( base_url: base_url, oauth2_scopes: [], - operation_id: 'ats_get_candidate_custom_field_definition', + operation_id: 'ats_get_candidate', security_source: @sdk_configuration.security_source ) @@ -5999,12 +5999,12 @@ def get_candidate_custom_field_definition(request, retries = nil, timeout_ms = n ), response: http_response ) - obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::CustomFieldDefinitionResultApiModel) - response = Models::Operations::AtsGetCandidateCustomFieldDefinitionResponse.new( + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::CandidateResult) + response = Models::Operations::AtsGetCandidateResponse.new( status_code: http_response.status, content_type: content_type, raw_response: http_response, - custom_field_definition_result_api_model: obj + candidate_result: obj ) return response @@ -6178,19 +6178,19 @@ def get_candidate_custom_field_definition(request, retries = nil, timeout_ms = n end - sig { params(request: T.nilable(Models::Operations::AtsGetCandidateNoteRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::AtsGetCandidateNoteResponse) } - def get_candidate_note(request, retries = nil, timeout_ms = nil) - # get_candidate_note - Get Candidate Note + sig { params(request: T.nilable(Models::Operations::AtsGetCandidateCustomFieldDefinitionRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::AtsGetCandidateCustomFieldDefinitionResponse) } + def get_candidate_custom_field_definition(request, retries = nil, timeout_ms = nil) + # get_candidate_custom_field_definition - Get Candidate Custom Field Definition url, params = @sdk_configuration.get_server_details base_url = Utils.template_url(url, params) url = Utils.generate_url( - Models::Operations::AtsGetCandidateNoteRequest, + Models::Operations::AtsGetCandidateCustomFieldDefinitionRequest, base_url, - '/unified/ats/candidates/{id}/notes/{subResourceId}', + '/unified/ats/custom_field_definitions/candidates/{id}', request ) headers = Utils.get_headers(request) - query_params = Utils.get_query_params(Models::Operations::AtsGetCandidateNoteRequest, request) + query_params = Utils.get_query_params(Models::Operations::AtsGetCandidateCustomFieldDefinitionRequest, request) headers['Accept'] = 'application/json' headers['user-agent'] = @sdk_configuration.user_agent retries ||= @sdk_configuration.retry_config @@ -6218,7 +6218,7 @@ def get_candidate_note(request, retries = nil, timeout_ms = nil) hook_ctx = SDKHooks::HookContext.new( base_url: base_url, oauth2_scopes: [], - operation_id: 'ats_get_candidate_note', + operation_id: 'ats_get_candidate_custom_field_definition', security_source: @sdk_configuration.security_source ) @@ -6275,12 +6275,12 @@ def get_candidate_note(request, retries = nil, timeout_ms = nil) ), response: http_response ) - obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::NoteResult) - response = Models::Operations::AtsGetCandidateNoteResponse.new( + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::CustomFieldDefinitionResultApiModel) + response = Models::Operations::AtsGetCandidateCustomFieldDefinitionResponse.new( status_code: http_response.status, content_type: content_type, raw_response: http_response, - note_result: obj + custom_field_definition_result_api_model: obj ) return response @@ -6454,19 +6454,19 @@ def get_candidate_note(request, retries = nil, timeout_ms = nil) end - sig { params(request: T.nilable(Models::Operations::AtsGetDepartmentRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::AtsGetDepartmentResponse) } - def get_department(request, retries = nil, timeout_ms = nil) - # get_department - Get Department + sig { params(request: T.nilable(Models::Operations::AtsGetCandidateNoteRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::AtsGetCandidateNoteResponse) } + def get_candidate_note(request, retries = nil, timeout_ms = nil) + # get_candidate_note - Get Candidate Note url, params = @sdk_configuration.get_server_details base_url = Utils.template_url(url, params) url = Utils.generate_url( - Models::Operations::AtsGetDepartmentRequest, + Models::Operations::AtsGetCandidateNoteRequest, base_url, - '/unified/ats/departments/{id}', + '/unified/ats/candidates/{id}/notes/{subResourceId}', request ) headers = Utils.get_headers(request) - query_params = Utils.get_query_params(Models::Operations::AtsGetDepartmentRequest, request) + query_params = Utils.get_query_params(Models::Operations::AtsGetCandidateNoteRequest, request) headers['Accept'] = 'application/json' headers['user-agent'] = @sdk_configuration.user_agent retries ||= @sdk_configuration.retry_config @@ -6494,7 +6494,7 @@ def get_department(request, retries = nil, timeout_ms = nil) hook_ctx = SDKHooks::HookContext.new( base_url: base_url, oauth2_scopes: [], - operation_id: 'ats_get_department', + operation_id: 'ats_get_candidate_note', security_source: @sdk_configuration.security_source ) @@ -6551,12 +6551,12 @@ def get_department(request, retries = nil, timeout_ms = nil) ), response: http_response ) - obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::DepartmentResult) - response = Models::Operations::AtsGetDepartmentResponse.new( + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::NoteResult) + response = Models::Operations::AtsGetCandidateNoteResponse.new( status_code: http_response.status, content_type: content_type, raw_response: http_response, - department_result: obj + note_result: obj ) return response @@ -6730,19 +6730,19 @@ def get_department(request, retries = nil, timeout_ms = nil) end - sig { params(request: T.nilable(Models::Operations::AtsGetInterviewRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::AtsGetInterviewResponse) } - def get_interview(request, retries = nil, timeout_ms = nil) - # get_interview - Get Interview + sig { params(request: T.nilable(Models::Operations::AtsGetDepartmentRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::AtsGetDepartmentResponse) } + def get_department(request, retries = nil, timeout_ms = nil) + # get_department - Get Department url, params = @sdk_configuration.get_server_details base_url = Utils.template_url(url, params) url = Utils.generate_url( - Models::Operations::AtsGetInterviewRequest, + Models::Operations::AtsGetDepartmentRequest, base_url, - '/unified/ats/interviews/{id}', + '/unified/ats/departments/{id}', request ) headers = Utils.get_headers(request) - query_params = Utils.get_query_params(Models::Operations::AtsGetInterviewRequest, request) + query_params = Utils.get_query_params(Models::Operations::AtsGetDepartmentRequest, request) headers['Accept'] = 'application/json' headers['user-agent'] = @sdk_configuration.user_agent retries ||= @sdk_configuration.retry_config @@ -6770,7 +6770,7 @@ def get_interview(request, retries = nil, timeout_ms = nil) hook_ctx = SDKHooks::HookContext.new( base_url: base_url, oauth2_scopes: [], - operation_id: 'ats_get_interview', + operation_id: 'ats_get_department', security_source: @sdk_configuration.security_source ) @@ -6827,12 +6827,12 @@ def get_interview(request, retries = nil, timeout_ms = nil) ), response: http_response ) - obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::InterviewsResult) - response = Models::Operations::AtsGetInterviewResponse.new( + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::DepartmentResult) + response = Models::Operations::AtsGetDepartmentResponse.new( status_code: http_response.status, content_type: content_type, raw_response: http_response, - interviews_result: obj + department_result: obj ) return response @@ -7006,19 +7006,19 @@ def get_interview(request, retries = nil, timeout_ms = nil) end - sig { params(request: T.nilable(Models::Operations::AtsGetInterviewStageRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::AtsGetInterviewStageResponse) } - def get_interview_stage(request, retries = nil, timeout_ms = nil) - # get_interview_stage - Get Interview Stage + sig { params(request: T.nilable(Models::Operations::AtsGetInterviewRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::AtsGetInterviewResponse) } + def get_interview(request, retries = nil, timeout_ms = nil) + # get_interview - Get Interview url, params = @sdk_configuration.get_server_details base_url = Utils.template_url(url, params) url = Utils.generate_url( - Models::Operations::AtsGetInterviewStageRequest, + Models::Operations::AtsGetInterviewRequest, base_url, - '/unified/ats/interview_stages/{id}', + '/unified/ats/interviews/{id}', request ) headers = Utils.get_headers(request) - query_params = Utils.get_query_params(Models::Operations::AtsGetInterviewStageRequest, request) + query_params = Utils.get_query_params(Models::Operations::AtsGetInterviewRequest, request) headers['Accept'] = 'application/json' headers['user-agent'] = @sdk_configuration.user_agent retries ||= @sdk_configuration.retry_config @@ -7046,7 +7046,7 @@ def get_interview_stage(request, retries = nil, timeout_ms = nil) hook_ctx = SDKHooks::HookContext.new( base_url: base_url, oauth2_scopes: [], - operation_id: 'ats_get_interview_stage', + operation_id: 'ats_get_interview', security_source: @sdk_configuration.security_source ) @@ -7103,12 +7103,12 @@ def get_interview_stage(request, retries = nil, timeout_ms = nil) ), response: http_response ) - obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::InterviewStageResult) - response = Models::Operations::AtsGetInterviewStageResponse.new( + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::InterviewsResult) + response = Models::Operations::AtsGetInterviewResponse.new( status_code: http_response.status, content_type: content_type, raw_response: http_response, - interview_stage_result: obj + interviews_result: obj ) return response @@ -7282,19 +7282,19 @@ def get_interview_stage(request, retries = nil, timeout_ms = nil) end - sig { params(request: T.nilable(Models::Operations::AtsGetJobRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::AtsGetJobResponse) } - def get_job(request, retries = nil, timeout_ms = nil) - # get_job - Get Job + sig { params(request: T.nilable(Models::Operations::AtsGetInterviewStageRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::AtsGetInterviewStageResponse) } + def get_interview_stage(request, retries = nil, timeout_ms = nil) + # get_interview_stage - Get Interview Stage url, params = @sdk_configuration.get_server_details base_url = Utils.template_url(url, params) url = Utils.generate_url( - Models::Operations::AtsGetJobRequest, + Models::Operations::AtsGetInterviewStageRequest, base_url, - '/unified/ats/jobs/{id}', + '/unified/ats/interview_stages/{id}', request ) headers = Utils.get_headers(request) - query_params = Utils.get_query_params(Models::Operations::AtsGetJobRequest, request) + query_params = Utils.get_query_params(Models::Operations::AtsGetInterviewStageRequest, request) headers['Accept'] = 'application/json' headers['user-agent'] = @sdk_configuration.user_agent retries ||= @sdk_configuration.retry_config @@ -7322,7 +7322,7 @@ def get_job(request, retries = nil, timeout_ms = nil) hook_ctx = SDKHooks::HookContext.new( base_url: base_url, oauth2_scopes: [], - operation_id: 'ats_get_job', + operation_id: 'ats_get_interview_stage', security_source: @sdk_configuration.security_source ) @@ -7379,12 +7379,12 @@ def get_job(request, retries = nil, timeout_ms = nil) ), response: http_response ) - obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::JobResult) - response = Models::Operations::AtsGetJobResponse.new( + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::InterviewStageResult) + response = Models::Operations::AtsGetInterviewStageResponse.new( status_code: http_response.status, content_type: content_type, raw_response: http_response, - job_result: obj + interview_stage_result: obj ) return response @@ -7558,19 +7558,19 @@ def get_job(request, retries = nil, timeout_ms = nil) end - sig { params(request: T.nilable(Models::Operations::AtsGetJobCustomFieldDefinitionRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::AtsGetJobCustomFieldDefinitionResponse) } - def get_job_custom_field_definition(request, retries = nil, timeout_ms = nil) - # get_job_custom_field_definition - Get Job Custom Field Definition + sig { params(request: T.nilable(Models::Operations::AtsGetJobRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::AtsGetJobResponse) } + def get_job(request, retries = nil, timeout_ms = nil) + # get_job - Get Job url, params = @sdk_configuration.get_server_details base_url = Utils.template_url(url, params) url = Utils.generate_url( - Models::Operations::AtsGetJobCustomFieldDefinitionRequest, + Models::Operations::AtsGetJobRequest, base_url, - '/unified/ats/custom_field_definitions/jobs/{id}', + '/unified/ats/jobs/{id}', request ) headers = Utils.get_headers(request) - query_params = Utils.get_query_params(Models::Operations::AtsGetJobCustomFieldDefinitionRequest, request) + query_params = Utils.get_query_params(Models::Operations::AtsGetJobRequest, request) headers['Accept'] = 'application/json' headers['user-agent'] = @sdk_configuration.user_agent retries ||= @sdk_configuration.retry_config @@ -7598,7 +7598,7 @@ def get_job_custom_field_definition(request, retries = nil, timeout_ms = nil) hook_ctx = SDKHooks::HookContext.new( base_url: base_url, oauth2_scopes: [], - operation_id: 'ats_get_job_custom_field_definition', + operation_id: 'ats_get_job', security_source: @sdk_configuration.security_source ) @@ -7655,12 +7655,12 @@ def get_job_custom_field_definition(request, retries = nil, timeout_ms = nil) ), response: http_response ) - obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::CustomFieldDefinitionResultApiModel) - response = Models::Operations::AtsGetJobCustomFieldDefinitionResponse.new( + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::JobResult) + response = Models::Operations::AtsGetJobResponse.new( status_code: http_response.status, content_type: content_type, raw_response: http_response, - custom_field_definition_result_api_model: obj + job_result: obj ) return response @@ -7834,19 +7834,19 @@ def get_job_custom_field_definition(request, retries = nil, timeout_ms = nil) end - sig { params(request: T.nilable(Models::Operations::AtsGetJobPostingRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::AtsGetJobPostingResponse) } - def get_job_posting(request, retries = nil, timeout_ms = nil) - # get_job_posting - Get Job Posting + sig { params(request: T.nilable(Models::Operations::AtsGetJobCustomFieldDefinitionRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::AtsGetJobCustomFieldDefinitionResponse) } + def get_job_custom_field_definition(request, retries = nil, timeout_ms = nil) + # get_job_custom_field_definition - Get Job Custom Field Definition url, params = @sdk_configuration.get_server_details base_url = Utils.template_url(url, params) url = Utils.generate_url( - Models::Operations::AtsGetJobPostingRequest, + Models::Operations::AtsGetJobCustomFieldDefinitionRequest, base_url, - '/unified/ats/job_postings/{id}', + '/unified/ats/custom_field_definitions/jobs/{id}', request ) headers = Utils.get_headers(request) - query_params = Utils.get_query_params(Models::Operations::AtsGetJobPostingRequest, request) + query_params = Utils.get_query_params(Models::Operations::AtsGetJobCustomFieldDefinitionRequest, request) headers['Accept'] = 'application/json' headers['user-agent'] = @sdk_configuration.user_agent retries ||= @sdk_configuration.retry_config @@ -7874,7 +7874,7 @@ def get_job_posting(request, retries = nil, timeout_ms = nil) hook_ctx = SDKHooks::HookContext.new( base_url: base_url, oauth2_scopes: [], - operation_id: 'ats_get_job_posting', + operation_id: 'ats_get_job_custom_field_definition', security_source: @sdk_configuration.security_source ) @@ -7931,12 +7931,12 @@ def get_job_posting(request, retries = nil, timeout_ms = nil) ), response: http_response ) - obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::JobPostingResult) - response = Models::Operations::AtsGetJobPostingResponse.new( + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::CustomFieldDefinitionResultApiModel) + response = Models::Operations::AtsGetJobCustomFieldDefinitionResponse.new( status_code: http_response.status, content_type: content_type, raw_response: http_response, - job_posting_result: obj + custom_field_definition_result_api_model: obj ) return response @@ -8110,19 +8110,19 @@ def get_job_posting(request, retries = nil, timeout_ms = nil) end - sig { params(request: T.nilable(Models::Operations::AtsGetListRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::AtsGetListResponse) } - def get_list(request, retries = nil, timeout_ms = nil) - # get_list - Get List + sig { params(request: T.nilable(Models::Operations::AtsGetJobPostingRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::AtsGetJobPostingResponse) } + def get_job_posting(request, retries = nil, timeout_ms = nil) + # get_job_posting - Get Job Posting url, params = @sdk_configuration.get_server_details base_url = Utils.template_url(url, params) url = Utils.generate_url( - Models::Operations::AtsGetListRequest, + Models::Operations::AtsGetJobPostingRequest, base_url, - '/unified/ats/lists/{id}', + '/unified/ats/job_postings/{id}', request ) headers = Utils.get_headers(request) - query_params = Utils.get_query_params(Models::Operations::AtsGetListRequest, request) + query_params = Utils.get_query_params(Models::Operations::AtsGetJobPostingRequest, request) headers['Accept'] = 'application/json' headers['user-agent'] = @sdk_configuration.user_agent retries ||= @sdk_configuration.retry_config @@ -8150,7 +8150,7 @@ def get_list(request, retries = nil, timeout_ms = nil) hook_ctx = SDKHooks::HookContext.new( base_url: base_url, oauth2_scopes: [], - operation_id: 'ats_get_list', + operation_id: 'ats_get_job_posting', security_source: @sdk_configuration.security_source ) @@ -8207,12 +8207,12 @@ def get_list(request, retries = nil, timeout_ms = nil) ), response: http_response ) - obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::ListResult) - response = Models::Operations::AtsGetListResponse.new( + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::JobPostingResult) + response = Models::Operations::AtsGetJobPostingResponse.new( status_code: http_response.status, content_type: content_type, raw_response: http_response, - list_result: obj + job_posting_result: obj ) return response @@ -8386,19 +8386,19 @@ def get_list(request, retries = nil, timeout_ms = nil) end - sig { params(request: T.nilable(Models::Operations::AtsGetLocationRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::AtsGetLocationResponse) } - def get_location(request, retries = nil, timeout_ms = nil) - # get_location - Get Location + sig { params(request: T.nilable(Models::Operations::AtsGetListRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::AtsGetListResponse) } + def get_list(request, retries = nil, timeout_ms = nil) + # get_list - Get List url, params = @sdk_configuration.get_server_details base_url = Utils.template_url(url, params) url = Utils.generate_url( - Models::Operations::AtsGetLocationRequest, + Models::Operations::AtsGetListRequest, base_url, - '/unified/ats/locations/{id}', + '/unified/ats/lists/{id}', request ) headers = Utils.get_headers(request) - query_params = Utils.get_query_params(Models::Operations::AtsGetLocationRequest, request) + query_params = Utils.get_query_params(Models::Operations::AtsGetListRequest, request) headers['Accept'] = 'application/json' headers['user-agent'] = @sdk_configuration.user_agent retries ||= @sdk_configuration.retry_config @@ -8426,7 +8426,7 @@ def get_location(request, retries = nil, timeout_ms = nil) hook_ctx = SDKHooks::HookContext.new( base_url: base_url, oauth2_scopes: [], - operation_id: 'ats_get_location', + operation_id: 'ats_get_list', security_source: @sdk_configuration.security_source ) @@ -8483,12 +8483,12 @@ def get_location(request, retries = nil, timeout_ms = nil) ), response: http_response ) - obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::ATSLocationResult) - response = Models::Operations::AtsGetLocationResponse.new( + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::ListResult) + response = Models::Operations::AtsGetListResponse.new( status_code: http_response.status, content_type: content_type, raw_response: http_response, - ats_location_result: obj + list_result: obj ) return response @@ -8662,19 +8662,19 @@ def get_location(request, retries = nil, timeout_ms = nil) end - sig { params(request: T.nilable(Models::Operations::AtsGetOfferRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::AtsGetOfferResponse) } - def get_offer(request, retries = nil, timeout_ms = nil) - # get_offer - Get Offer + sig { params(request: T.nilable(Models::Operations::AtsGetLocationRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::AtsGetLocationResponse) } + def get_location(request, retries = nil, timeout_ms = nil) + # get_location - Get Location url, params = @sdk_configuration.get_server_details base_url = Utils.template_url(url, params) url = Utils.generate_url( - Models::Operations::AtsGetOfferRequest, + Models::Operations::AtsGetLocationRequest, base_url, - '/unified/ats/offers/{id}', + '/unified/ats/locations/{id}', request ) headers = Utils.get_headers(request) - query_params = Utils.get_query_params(Models::Operations::AtsGetOfferRequest, request) + query_params = Utils.get_query_params(Models::Operations::AtsGetLocationRequest, request) headers['Accept'] = 'application/json' headers['user-agent'] = @sdk_configuration.user_agent retries ||= @sdk_configuration.retry_config @@ -8702,7 +8702,7 @@ def get_offer(request, retries = nil, timeout_ms = nil) hook_ctx = SDKHooks::HookContext.new( base_url: base_url, oauth2_scopes: [], - operation_id: 'ats_get_offer', + operation_id: 'ats_get_location', security_source: @sdk_configuration.security_source ) @@ -8759,12 +8759,12 @@ def get_offer(request, retries = nil, timeout_ms = nil) ), response: http_response ) - obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::OffersResult) - response = Models::Operations::AtsGetOfferResponse.new( + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::ATSLocationResult) + response = Models::Operations::AtsGetLocationResponse.new( status_code: http_response.status, content_type: content_type, raw_response: http_response, - offers_result: obj + ats_location_result: obj ) return response @@ -8938,19 +8938,19 @@ def get_offer(request, retries = nil, timeout_ms = nil) end - sig { params(request: T.nilable(Models::Operations::AtsGetRejectedReasonRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::AtsGetRejectedReasonResponse) } - def get_rejected_reason(request, retries = nil, timeout_ms = nil) - # get_rejected_reason - Get Rejected Reason + sig { params(request: T.nilable(Models::Operations::AtsGetOfferRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::AtsGetOfferResponse) } + def get_offer(request, retries = nil, timeout_ms = nil) + # get_offer - Get Offer url, params = @sdk_configuration.get_server_details base_url = Utils.template_url(url, params) url = Utils.generate_url( - Models::Operations::AtsGetRejectedReasonRequest, + Models::Operations::AtsGetOfferRequest, base_url, - '/unified/ats/rejected_reasons/{id}', + '/unified/ats/offers/{id}', request ) headers = Utils.get_headers(request) - query_params = Utils.get_query_params(Models::Operations::AtsGetRejectedReasonRequest, request) + query_params = Utils.get_query_params(Models::Operations::AtsGetOfferRequest, request) headers['Accept'] = 'application/json' headers['user-agent'] = @sdk_configuration.user_agent retries ||= @sdk_configuration.retry_config @@ -8978,7 +8978,7 @@ def get_rejected_reason(request, retries = nil, timeout_ms = nil) hook_ctx = SDKHooks::HookContext.new( base_url: base_url, oauth2_scopes: [], - operation_id: 'ats_get_rejected_reason', + operation_id: 'ats_get_offer', security_source: @sdk_configuration.security_source ) @@ -9035,12 +9035,12 @@ def get_rejected_reason(request, retries = nil, timeout_ms = nil) ), response: http_response ) - obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::RejectedReasonResult) - response = Models::Operations::AtsGetRejectedReasonResponse.new( + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::OffersResult) + response = Models::Operations::AtsGetOfferResponse.new( status_code: http_response.status, content_type: content_type, raw_response: http_response, - rejected_reason_result: obj + offers_result: obj ) return response @@ -9214,19 +9214,19 @@ def get_rejected_reason(request, retries = nil, timeout_ms = nil) end - sig { params(request: T.nilable(Models::Operations::AtsGetUserRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::AtsGetUserResponse) } - def get_user(request, retries = nil, timeout_ms = nil) - # get_user - Get User + sig { params(request: T.nilable(Models::Operations::AtsGetRejectedReasonRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::AtsGetRejectedReasonResponse) } + def get_rejected_reason(request, retries = nil, timeout_ms = nil) + # get_rejected_reason - Get Rejected Reason url, params = @sdk_configuration.get_server_details base_url = Utils.template_url(url, params) url = Utils.generate_url( - Models::Operations::AtsGetUserRequest, + Models::Operations::AtsGetRejectedReasonRequest, base_url, - '/unified/ats/users/{id}', + '/unified/ats/rejected_reasons/{id}', request ) headers = Utils.get_headers(request) - query_params = Utils.get_query_params(Models::Operations::AtsGetUserRequest, request) + query_params = Utils.get_query_params(Models::Operations::AtsGetRejectedReasonRequest, request) headers['Accept'] = 'application/json' headers['user-agent'] = @sdk_configuration.user_agent retries ||= @sdk_configuration.retry_config @@ -9254,7 +9254,7 @@ def get_user(request, retries = nil, timeout_ms = nil) hook_ctx = SDKHooks::HookContext.new( base_url: base_url, oauth2_scopes: [], - operation_id: 'ats_get_user', + operation_id: 'ats_get_rejected_reason', security_source: @sdk_configuration.security_source ) @@ -9311,12 +9311,12 @@ def get_user(request, retries = nil, timeout_ms = nil) ), response: http_response ) - obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::UserResult) - response = Models::Operations::AtsGetUserResponse.new( + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::RejectedReasonResult) + response = Models::Operations::AtsGetRejectedReasonResponse.new( status_code: http_response.status, content_type: content_type, raw_response: http_response, - user_result: obj + rejected_reason_result: obj ) return response @@ -9490,19 +9490,19 @@ def get_user(request, retries = nil, timeout_ms = nil) end - sig { params(request: T.nilable(Models::Operations::AtsListApplicationChangesRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::AtsListApplicationChangesResponse) } - def list_application_changes(request, retries = nil, timeout_ms = nil) - # list_application_changes - List Application Changes + sig { params(request: T.nilable(Models::Operations::AtsGetUserRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::AtsGetUserResponse) } + def get_user(request, retries = nil, timeout_ms = nil) + # get_user - Get User url, params = @sdk_configuration.get_server_details base_url = Utils.template_url(url, params) url = Utils.generate_url( - Models::Operations::AtsListApplicationChangesRequest, + Models::Operations::AtsGetUserRequest, base_url, - '/unified/ats/applications/{id}/changes', + '/unified/ats/users/{id}', request ) headers = Utils.get_headers(request) - query_params = Utils.get_query_params(Models::Operations::AtsListApplicationChangesRequest, request) + query_params = Utils.get_query_params(Models::Operations::AtsGetUserRequest, request) headers['Accept'] = 'application/json' headers['user-agent'] = @sdk_configuration.user_agent retries ||= @sdk_configuration.retry_config @@ -9530,7 +9530,7 @@ def list_application_changes(request, retries = nil, timeout_ms = nil) hook_ctx = SDKHooks::HookContext.new( base_url: base_url, oauth2_scopes: [], - operation_id: 'ats_list_application_changes', + operation_id: 'ats_get_user', security_source: @sdk_configuration.security_source ) @@ -9587,12 +9587,12 @@ def list_application_changes(request, retries = nil, timeout_ms = nil) ), response: http_response ) - obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::ApplicationChangesPaginated) - response = Models::Operations::AtsListApplicationChangesResponse.new( + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::UserResult) + response = Models::Operations::AtsGetUserResponse.new( status_code: http_response.status, content_type: content_type, raw_response: http_response, - application_changes_paginated: obj + user_result: obj ) return response @@ -9766,14 +9766,19 @@ def list_application_changes(request, retries = nil, timeout_ms = nil) end - sig { params(request: T.nilable(Models::Operations::AtsListApplicationCustomFieldDefinitionsRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::AtsListApplicationCustomFieldDefinitionsResponse) } - def list_application_custom_field_definitions(request, retries = nil, timeout_ms = nil) - # list_application_custom_field_definitions - List Application Custom Field Definitions + sig { params(request: T.nilable(Models::Operations::AtsListApplicationChangesRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::AtsListApplicationChangesResponse) } + def list_application_changes(request, retries = nil, timeout_ms = nil) + # list_application_changes - List Application Changes url, params = @sdk_configuration.get_server_details base_url = Utils.template_url(url, params) - url = "#{base_url}/unified/ats/custom_field_definitions/applications" + url = Utils.generate_url( + Models::Operations::AtsListApplicationChangesRequest, + base_url, + '/unified/ats/applications/{id}/changes', + request + ) headers = Utils.get_headers(request) - query_params = Utils.get_query_params(Models::Operations::AtsListApplicationCustomFieldDefinitionsRequest, request) + query_params = Utils.get_query_params(Models::Operations::AtsListApplicationChangesRequest, request) headers['Accept'] = 'application/json' headers['user-agent'] = @sdk_configuration.user_agent retries ||= @sdk_configuration.retry_config @@ -9801,7 +9806,7 @@ def list_application_custom_field_definitions(request, retries = nil, timeout_ms hook_ctx = SDKHooks::HookContext.new( base_url: base_url, oauth2_scopes: [], - operation_id: 'ats_list_application_custom_field_definitions', + operation_id: 'ats_list_application_changes', security_source: @sdk_configuration.security_source ) @@ -9858,12 +9863,554 @@ def list_application_custom_field_definitions(request, retries = nil, timeout_ms ), response: http_response ) - obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::CustomFieldDefinitionsPaginated) - response = Models::Operations::AtsListApplicationCustomFieldDefinitionsResponse.new( + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::ApplicationChangesPaginated) + response = Models::Operations::AtsListApplicationChangesResponse.new( status_code: http_response.status, content_type: content_type, raw_response: http_response, - custom_field_definitions_paginated: obj + application_changes_paginated: obj + ) + + return response + else + raise ::StackOne::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'Unknown content type received' + end + elsif Utils.match_status_code(http_response.status, ['400']) + if Utils.match_content_type(content_type, 'application/json') + http_response = @sdk_configuration.hooks.after_success( + hook_ctx: SDKHooks::AfterSuccessHookContext.new( + hook_ctx: hook_ctx + ), + response: http_response + ) + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Errors::BadRequestResponse) + throw obj + else + raise ::StackOne::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'Unknown content type received' + end + elsif Utils.match_status_code(http_response.status, ['401']) + if Utils.match_content_type(content_type, 'application/json') + http_response = @sdk_configuration.hooks.after_success( + hook_ctx: SDKHooks::AfterSuccessHookContext.new( + hook_ctx: hook_ctx + ), + response: http_response + ) + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Errors::UnauthorizedResponse) + throw obj + else + raise ::StackOne::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'Unknown content type received' + end + elsif Utils.match_status_code(http_response.status, ['403']) + if Utils.match_content_type(content_type, 'application/json') + http_response = @sdk_configuration.hooks.after_success( + hook_ctx: SDKHooks::AfterSuccessHookContext.new( + hook_ctx: hook_ctx + ), + response: http_response + ) + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Errors::ForbiddenResponse) + throw obj + else + raise ::StackOne::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'Unknown content type received' + end + elsif Utils.match_status_code(http_response.status, ['404']) + if Utils.match_content_type(content_type, 'application/json') + http_response = @sdk_configuration.hooks.after_success( + hook_ctx: SDKHooks::AfterSuccessHookContext.new( + hook_ctx: hook_ctx + ), + response: http_response + ) + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Errors::NotFoundResponse) + throw obj + else + raise ::StackOne::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'Unknown content type received' + end + elsif Utils.match_status_code(http_response.status, ['408']) + if Utils.match_content_type(content_type, 'application/json') + http_response = @sdk_configuration.hooks.after_success( + hook_ctx: SDKHooks::AfterSuccessHookContext.new( + hook_ctx: hook_ctx + ), + response: http_response + ) + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Errors::RequestTimedOutResponse) + throw obj + else + raise ::StackOne::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'Unknown content type received' + end + elsif Utils.match_status_code(http_response.status, ['409']) + if Utils.match_content_type(content_type, 'application/json') + http_response = @sdk_configuration.hooks.after_success( + hook_ctx: SDKHooks::AfterSuccessHookContext.new( + hook_ctx: hook_ctx + ), + response: http_response + ) + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Errors::ConflictResponse) + throw obj + else + raise ::StackOne::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'Unknown content type received' + end + elsif Utils.match_status_code(http_response.status, ['412']) + if Utils.match_content_type(content_type, 'application/json') + http_response = @sdk_configuration.hooks.after_success( + hook_ctx: SDKHooks::AfterSuccessHookContext.new( + hook_ctx: hook_ctx + ), + response: http_response + ) + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Errors::PreconditionFailedResponse) + throw obj + else + raise ::StackOne::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'Unknown content type received' + end + elsif Utils.match_status_code(http_response.status, ['422']) + if Utils.match_content_type(content_type, 'application/json') + http_response = @sdk_configuration.hooks.after_success( + hook_ctx: SDKHooks::AfterSuccessHookContext.new( + hook_ctx: hook_ctx + ), + response: http_response + ) + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Errors::UnprocessableEntityResponse) + throw obj + else + raise ::StackOne::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'Unknown content type received' + end + elsif Utils.match_status_code(http_response.status, ['429']) + if Utils.match_content_type(content_type, 'application/json') + http_response = @sdk_configuration.hooks.after_success( + hook_ctx: SDKHooks::AfterSuccessHookContext.new( + hook_ctx: hook_ctx + ), + response: http_response + ) + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Errors::TooManyRequestsResponse) + throw obj + else + raise ::StackOne::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'Unknown content type received' + end + elsif Utils.match_status_code(http_response.status, ['500']) + if Utils.match_content_type(content_type, 'application/json') + http_response = @sdk_configuration.hooks.after_success( + hook_ctx: SDKHooks::AfterSuccessHookContext.new( + hook_ctx: hook_ctx + ), + response: http_response + ) + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Errors::InternalServerErrorResponse) + throw obj + else + raise ::StackOne::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'Unknown content type received' + end + elsif Utils.match_status_code(http_response.status, ['501']) + if Utils.match_content_type(content_type, 'application/json') + http_response = @sdk_configuration.hooks.after_success( + hook_ctx: SDKHooks::AfterSuccessHookContext.new( + hook_ctx: hook_ctx + ), + response: http_response + ) + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Errors::NotImplementedResponse) + throw obj + else + raise ::StackOne::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'Unknown content type received' + end + elsif Utils.match_status_code(http_response.status, ['502']) + if Utils.match_content_type(content_type, 'application/json') + http_response = @sdk_configuration.hooks.after_success( + hook_ctx: SDKHooks::AfterSuccessHookContext.new( + hook_ctx: hook_ctx + ), + response: http_response + ) + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Errors::BadGatewayResponse) + throw obj + else + raise ::StackOne::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'Unknown content type received' + end + elsif Utils.match_status_code(http_response.status, ['4XX']) + raise ::StackOne::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'API error occurred' + elsif Utils.match_status_code(http_response.status, ['5XX']) + raise ::StackOne::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'API error occurred' + else + raise ::StackOne::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'Unknown status code received' + + end + end + + + sig { params(request: T.nilable(Models::Operations::AtsListApplicationCustomFieldDefinitionsRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::AtsListApplicationCustomFieldDefinitionsResponse) } + def list_application_custom_field_definitions(request, retries = nil, timeout_ms = nil) + # list_application_custom_field_definitions - List Application Custom Field Definitions + url, params = @sdk_configuration.get_server_details + base_url = Utils.template_url(url, params) + url = "#{base_url}/unified/ats/custom_field_definitions/applications" + headers = Utils.get_headers(request) + query_params = Utils.get_query_params(Models::Operations::AtsListApplicationCustomFieldDefinitionsRequest, request) + headers['Accept'] = 'application/json' + headers['user-agent'] = @sdk_configuration.user_agent + retries ||= @sdk_configuration.retry_config + retries ||= Utils::RetryConfig.new( + backoff: Utils::BackoffStrategy.new( + exponent: 1.5, + initial_interval: 500, + max_elapsed_time: 3_600_000, + max_interval: 60_000 + ), + retry_connection_errors: true, + strategy: 'backoff' + ) + retry_options = retries.to_faraday_retry_options(initial_time: Time.now) + retry_options[:retry_statuses] = [429, 408] + + security = !@sdk_configuration.nil? && !@sdk_configuration.security_source.nil? ? @sdk_configuration.security_source.call : nil + + timeout = (timeout_ms.to_f / 1000) unless timeout_ms.nil? + timeout ||= @sdk_configuration.timeout + + connection = @sdk_configuration.client.dup + connection.request :retry, retry_options + + hook_ctx = SDKHooks::HookContext.new( + base_url: base_url, + oauth2_scopes: [], + operation_id: 'ats_list_application_custom_field_definitions', + security_source: @sdk_configuration.security_source + ) + + error = T.let(nil, T.nilable(StandardError)) + http_response = T.let(nil, T.nilable(Faraday::Response)) + + + begin + http_response = connection.get(url) do |req| + req.headers.merge!(headers) + req.options.timeout = timeout unless timeout.nil? + req.params = query_params + Utils.configure_request_security(req, security) + + @sdk_configuration.hooks.before_request( + hook_ctx: SDKHooks::BeforeRequestHookContext.new( + hook_ctx: hook_ctx + ), + request: req + ) + end + rescue StandardError => e + error = e + ensure + if http_response.nil? || Utils.error_status?(http_response.status) + http_response = @sdk_configuration.hooks.after_error( + error: error, + hook_ctx: SDKHooks::AfterErrorHookContext.new( + hook_ctx: hook_ctx + ), + response: http_response + ) + else + http_response = @sdk_configuration.hooks.after_success( + hook_ctx: SDKHooks::AfterSuccessHookContext.new( + hook_ctx: hook_ctx + ), + response: http_response + ) + end + + if http_response.nil? + raise error if !error.nil? + raise 'no response' + end + end + + content_type = http_response.headers.fetch('Content-Type', 'application/octet-stream') + if Utils.match_status_code(http_response.status, ['200']) + if Utils.match_content_type(content_type, 'application/json') + http_response = @sdk_configuration.hooks.after_success( + hook_ctx: SDKHooks::AfterSuccessHookContext.new( + hook_ctx: hook_ctx + ), + response: http_response + ) + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::CustomFieldDefinitionsPaginated) + response = Models::Operations::AtsListApplicationCustomFieldDefinitionsResponse.new( + status_code: http_response.status, + content_type: content_type, + raw_response: http_response, + custom_field_definitions_paginated: obj + ) + + return response + else + raise ::StackOne::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'Unknown content type received' + end + elsif Utils.match_status_code(http_response.status, ['400']) + if Utils.match_content_type(content_type, 'application/json') + http_response = @sdk_configuration.hooks.after_success( + hook_ctx: SDKHooks::AfterSuccessHookContext.new( + hook_ctx: hook_ctx + ), + response: http_response + ) + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Errors::BadRequestResponse) + throw obj + else + raise ::StackOne::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'Unknown content type received' + end + elsif Utils.match_status_code(http_response.status, ['401']) + if Utils.match_content_type(content_type, 'application/json') + http_response = @sdk_configuration.hooks.after_success( + hook_ctx: SDKHooks::AfterSuccessHookContext.new( + hook_ctx: hook_ctx + ), + response: http_response + ) + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Errors::UnauthorizedResponse) + throw obj + else + raise ::StackOne::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'Unknown content type received' + end + elsif Utils.match_status_code(http_response.status, ['403']) + if Utils.match_content_type(content_type, 'application/json') + http_response = @sdk_configuration.hooks.after_success( + hook_ctx: SDKHooks::AfterSuccessHookContext.new( + hook_ctx: hook_ctx + ), + response: http_response + ) + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Errors::ForbiddenResponse) + throw obj + else + raise ::StackOne::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'Unknown content type received' + end + elsif Utils.match_status_code(http_response.status, ['404']) + if Utils.match_content_type(content_type, 'application/json') + http_response = @sdk_configuration.hooks.after_success( + hook_ctx: SDKHooks::AfterSuccessHookContext.new( + hook_ctx: hook_ctx + ), + response: http_response + ) + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Errors::NotFoundResponse) + throw obj + else + raise ::StackOne::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'Unknown content type received' + end + elsif Utils.match_status_code(http_response.status, ['408']) + if Utils.match_content_type(content_type, 'application/json') + http_response = @sdk_configuration.hooks.after_success( + hook_ctx: SDKHooks::AfterSuccessHookContext.new( + hook_ctx: hook_ctx + ), + response: http_response + ) + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Errors::RequestTimedOutResponse) + throw obj + else + raise ::StackOne::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'Unknown content type received' + end + elsif Utils.match_status_code(http_response.status, ['409']) + if Utils.match_content_type(content_type, 'application/json') + http_response = @sdk_configuration.hooks.after_success( + hook_ctx: SDKHooks::AfterSuccessHookContext.new( + hook_ctx: hook_ctx + ), + response: http_response + ) + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Errors::ConflictResponse) + throw obj + else + raise ::StackOne::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'Unknown content type received' + end + elsif Utils.match_status_code(http_response.status, ['412']) + if Utils.match_content_type(content_type, 'application/json') + http_response = @sdk_configuration.hooks.after_success( + hook_ctx: SDKHooks::AfterSuccessHookContext.new( + hook_ctx: hook_ctx + ), + response: http_response + ) + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Errors::PreconditionFailedResponse) + throw obj + else + raise ::StackOne::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'Unknown content type received' + end + elsif Utils.match_status_code(http_response.status, ['422']) + if Utils.match_content_type(content_type, 'application/json') + http_response = @sdk_configuration.hooks.after_success( + hook_ctx: SDKHooks::AfterSuccessHookContext.new( + hook_ctx: hook_ctx + ), + response: http_response + ) + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Errors::UnprocessableEntityResponse) + throw obj + else + raise ::StackOne::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'Unknown content type received' + end + elsif Utils.match_status_code(http_response.status, ['429']) + if Utils.match_content_type(content_type, 'application/json') + http_response = @sdk_configuration.hooks.after_success( + hook_ctx: SDKHooks::AfterSuccessHookContext.new( + hook_ctx: hook_ctx + ), + response: http_response + ) + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Errors::TooManyRequestsResponse) + throw obj + else + raise ::StackOne::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'Unknown content type received' + end + elsif Utils.match_status_code(http_response.status, ['500']) + if Utils.match_content_type(content_type, 'application/json') + http_response = @sdk_configuration.hooks.after_success( + hook_ctx: SDKHooks::AfterSuccessHookContext.new( + hook_ctx: hook_ctx + ), + response: http_response + ) + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Errors::InternalServerErrorResponse) + throw obj + else + raise ::StackOne::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'Unknown content type received' + end + elsif Utils.match_status_code(http_response.status, ['501']) + if Utils.match_content_type(content_type, 'application/json') + http_response = @sdk_configuration.hooks.after_success( + hook_ctx: SDKHooks::AfterSuccessHookContext.new( + hook_ctx: hook_ctx + ), + response: http_response + ) + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Errors::NotImplementedResponse) + throw obj + else + raise ::StackOne::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'Unknown content type received' + end + elsif Utils.match_status_code(http_response.status, ['502']) + if Utils.match_content_type(content_type, 'application/json') + http_response = @sdk_configuration.hooks.after_success( + hook_ctx: SDKHooks::AfterSuccessHookContext.new( + hook_ctx: hook_ctx + ), + response: http_response + ) + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Errors::BadGatewayResponse) + throw obj + else + raise ::StackOne::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'Unknown content type received' + end + elsif Utils.match_status_code(http_response.status, ['4XX']) + raise ::StackOne::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'API error occurred' + elsif Utils.match_status_code(http_response.status, ['5XX']) + raise ::StackOne::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'API error occurred' + else + raise ::StackOne::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'Unknown status code received' + + end + end + + + sig { params(request: T.nilable(Models::Operations::AtsListApplicationDocumentCategoriesRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::AtsListApplicationDocumentCategoriesResponse) } + def list_application_document_categories(request, retries = nil, timeout_ms = nil) + # list_application_document_categories - List Application Document Categories + url, params = @sdk_configuration.get_server_details + base_url = Utils.template_url(url, params) + url = "#{base_url}/unified/ats/documents/application_categories" + headers = Utils.get_headers(request) + query_params = Utils.get_query_params(Models::Operations::AtsListApplicationDocumentCategoriesRequest, request) + headers['Accept'] = 'application/json' + headers['user-agent'] = @sdk_configuration.user_agent + retries ||= @sdk_configuration.retry_config + retries ||= Utils::RetryConfig.new( + backoff: Utils::BackoffStrategy.new( + exponent: 1.5, + initial_interval: 500, + max_elapsed_time: 3_600_000, + max_interval: 60_000 + ), + retry_connection_errors: true, + strategy: 'backoff' + ) + retry_options = retries.to_faraday_retry_options(initial_time: Time.now) + retry_options[:retry_statuses] = [429, 408] + + security = !@sdk_configuration.nil? && !@sdk_configuration.security_source.nil? ? @sdk_configuration.security_source.call : nil + + timeout = (timeout_ms.to_f / 1000) unless timeout_ms.nil? + timeout ||= @sdk_configuration.timeout + + connection = @sdk_configuration.client.dup + connection.request :retry, retry_options + + hook_ctx = SDKHooks::HookContext.new( + base_url: base_url, + oauth2_scopes: [], + operation_id: 'ats_list_application_document_categories', + security_source: @sdk_configuration.security_source + ) + + error = T.let(nil, T.nilable(StandardError)) + http_response = T.let(nil, T.nilable(Faraday::Response)) + + + begin + http_response = connection.get(url) do |req| + req.headers.merge!(headers) + req.options.timeout = timeout unless timeout.nil? + req.params = query_params + Utils.configure_request_security(req, security) + + @sdk_configuration.hooks.before_request( + hook_ctx: SDKHooks::BeforeRequestHookContext.new( + hook_ctx: hook_ctx + ), + request: req + ) + end + rescue StandardError => e + error = e + ensure + if http_response.nil? || Utils.error_status?(http_response.status) + http_response = @sdk_configuration.hooks.after_error( + error: error, + hook_ctx: SDKHooks::AfterErrorHookContext.new( + hook_ctx: hook_ctx + ), + response: http_response + ) + else + http_response = @sdk_configuration.hooks.after_success( + hook_ctx: SDKHooks::AfterSuccessHookContext.new( + hook_ctx: hook_ctx + ), + response: http_response + ) + end + + if http_response.nil? + raise error if !error.nil? + raise 'no response' + end + end + + content_type = http_response.headers.fetch('Content-Type', 'application/octet-stream') + if Utils.match_status_code(http_response.status, ['200']) + if Utils.match_content_type(content_type, 'application/json') + http_response = @sdk_configuration.hooks.after_success( + hook_ctx: SDKHooks::AfterSuccessHookContext.new( + hook_ctx: hook_ctx + ), + response: http_response + ) + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::ReferencePaginated) + response = Models::Operations::AtsListApplicationDocumentCategoriesResponse.new( + status_code: http_response.status, + content_type: content_type, + raw_response: http_response, + reference_paginated: obj ) return response diff --git a/lib/stack_one/hris.rb b/lib/stack_one/hris.rb index 904bf3b6..a225566f 100644 --- a/lib/stack_one/hris.rb +++ b/lib/stack_one/hris.rb @@ -8131,19 +8131,19 @@ def get_position(request, retries = nil, timeout_ms = nil) end - sig { params(request: T.nilable(Models::Operations::HrisGetTaskRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::HrisGetTaskResponse) } - def get_task(request, retries = nil, timeout_ms = nil) - # get_task - Get Task + sig { params(request: T.nilable(Models::Operations::HrisGetShiftRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::HrisGetShiftResponse) } + def get_shift(request, retries = nil, timeout_ms = nil) + # get_shift - Get Shift url, params = @sdk_configuration.get_server_details base_url = Utils.template_url(url, params) url = Utils.generate_url( - Models::Operations::HrisGetTaskRequest, + Models::Operations::HrisGetShiftRequest, base_url, - '/unified/hris/tasks/{id}', + '/unified/hris/shifts/{id}', request ) headers = Utils.get_headers(request) - query_params = Utils.get_query_params(Models::Operations::HrisGetTaskRequest, request) + query_params = Utils.get_query_params(Models::Operations::HrisGetShiftRequest, request) headers['Accept'] = 'application/json' headers['user-agent'] = @sdk_configuration.user_agent retries ||= @sdk_configuration.retry_config @@ -8171,7 +8171,7 @@ def get_task(request, retries = nil, timeout_ms = nil) hook_ctx = SDKHooks::HookContext.new( base_url: base_url, oauth2_scopes: [], - operation_id: 'hris_get_task', + operation_id: 'hris_get_shift', security_source: @sdk_configuration.security_source ) @@ -8228,12 +8228,12 @@ def get_task(request, retries = nil, timeout_ms = nil) ), response: http_response ) - obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::TaskResult) - response = Models::Operations::HrisGetTaskResponse.new( + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::HrisShiftResult) + response = Models::Operations::HrisGetShiftResponse.new( status_code: http_response.status, content_type: content_type, raw_response: http_response, - task_result: obj + hris_shift_result: obj ) return response @@ -8407,19 +8407,19 @@ def get_task(request, retries = nil, timeout_ms = nil) end - sig { params(request: T.nilable(Models::Operations::HrisGetTeamGroupRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::HrisGetTeamGroupResponse) } - def get_team_group(request, retries = nil, timeout_ms = nil) - # get_team_group - Get Team Group + sig { params(request: T.nilable(Models::Operations::HrisGetTaskRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::HrisGetTaskResponse) } + def get_task(request, retries = nil, timeout_ms = nil) + # get_task - Get Task url, params = @sdk_configuration.get_server_details base_url = Utils.template_url(url, params) url = Utils.generate_url( - Models::Operations::HrisGetTeamGroupRequest, + Models::Operations::HrisGetTaskRequest, base_url, - '/unified/hris/groups/teams/{id}', + '/unified/hris/tasks/{id}', request ) headers = Utils.get_headers(request) - query_params = Utils.get_query_params(Models::Operations::HrisGetTeamGroupRequest, request) + query_params = Utils.get_query_params(Models::Operations::HrisGetTaskRequest, request) headers['Accept'] = 'application/json' headers['user-agent'] = @sdk_configuration.user_agent retries ||= @sdk_configuration.retry_config @@ -8447,7 +8447,7 @@ def get_team_group(request, retries = nil, timeout_ms = nil) hook_ctx = SDKHooks::HookContext.new( base_url: base_url, oauth2_scopes: [], - operation_id: 'hris_get_team_group', + operation_id: 'hris_get_task', security_source: @sdk_configuration.security_source ) @@ -8504,12 +8504,12 @@ def get_team_group(request, retries = nil, timeout_ms = nil) ), response: http_response ) - obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::HRISTeamsResult) - response = Models::Operations::HrisGetTeamGroupResponse.new( + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::TaskResult) + response = Models::Operations::HrisGetTaskResponse.new( status_code: http_response.status, content_type: content_type, raw_response: http_response, - hris_teams_result: obj + task_result: obj ) return response @@ -8683,19 +8683,19 @@ def get_team_group(request, retries = nil, timeout_ms = nil) end - sig { params(request: T.nilable(Models::Operations::HrisGetTimeEntriesRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::HrisGetTimeEntriesResponse) } - def get_time_entries(request, retries = nil, timeout_ms = nil) - # get_time_entries - Get Time Entry + sig { params(request: T.nilable(Models::Operations::HrisGetTeamGroupRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::HrisGetTeamGroupResponse) } + def get_team_group(request, retries = nil, timeout_ms = nil) + # get_team_group - Get Team Group url, params = @sdk_configuration.get_server_details base_url = Utils.template_url(url, params) url = Utils.generate_url( - Models::Operations::HrisGetTimeEntriesRequest, + Models::Operations::HrisGetTeamGroupRequest, base_url, - '/unified/hris/time_entries/{id}', + '/unified/hris/groups/teams/{id}', request ) headers = Utils.get_headers(request) - query_params = Utils.get_query_params(Models::Operations::HrisGetTimeEntriesRequest, request) + query_params = Utils.get_query_params(Models::Operations::HrisGetTeamGroupRequest, request) headers['Accept'] = 'application/json' headers['user-agent'] = @sdk_configuration.user_agent retries ||= @sdk_configuration.retry_config @@ -8723,7 +8723,7 @@ def get_time_entries(request, retries = nil, timeout_ms = nil) hook_ctx = SDKHooks::HookContext.new( base_url: base_url, oauth2_scopes: [], - operation_id: 'hris_get_time_entries', + operation_id: 'hris_get_team_group', security_source: @sdk_configuration.security_source ) @@ -8780,12 +8780,12 @@ def get_time_entries(request, retries = nil, timeout_ms = nil) ), response: http_response ) - obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::TimeEntriesResult) - response = Models::Operations::HrisGetTimeEntriesResponse.new( + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::HRISTeamsResult) + response = Models::Operations::HrisGetTeamGroupResponse.new( status_code: http_response.status, content_type: content_type, raw_response: http_response, - time_entries_result: obj + hris_teams_result: obj ) return response @@ -8959,19 +8959,19 @@ def get_time_entries(request, retries = nil, timeout_ms = nil) end - sig { params(request: T.nilable(Models::Operations::HrisGetTimeOffPolicyRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::HrisGetTimeOffPolicyResponse) } - def get_time_off_policy(request, retries = nil, timeout_ms = nil) - # get_time_off_policy - Get Time Off Policy + sig { params(request: T.nilable(Models::Operations::HrisGetTimeEntriesRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::HrisGetTimeEntriesResponse) } + def get_time_entries(request, retries = nil, timeout_ms = nil) + # get_time_entries - Get Time Entry url, params = @sdk_configuration.get_server_details base_url = Utils.template_url(url, params) url = Utils.generate_url( - Models::Operations::HrisGetTimeOffPolicyRequest, + Models::Operations::HrisGetTimeEntriesRequest, base_url, - '/unified/hris/time_off_policies/{id}', + '/unified/hris/time_entries/{id}', request ) headers = Utils.get_headers(request) - query_params = Utils.get_query_params(Models::Operations::HrisGetTimeOffPolicyRequest, request) + query_params = Utils.get_query_params(Models::Operations::HrisGetTimeEntriesRequest, request) headers['Accept'] = 'application/json' headers['user-agent'] = @sdk_configuration.user_agent retries ||= @sdk_configuration.retry_config @@ -8999,7 +8999,7 @@ def get_time_off_policy(request, retries = nil, timeout_ms = nil) hook_ctx = SDKHooks::HookContext.new( base_url: base_url, oauth2_scopes: [], - operation_id: 'hris_get_time_off_policy', + operation_id: 'hris_get_time_entries', security_source: @sdk_configuration.security_source ) @@ -9056,12 +9056,12 @@ def get_time_off_policy(request, retries = nil, timeout_ms = nil) ), response: http_response ) - obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::TimeOffPolicyResult) - response = Models::Operations::HrisGetTimeOffPolicyResponse.new( + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::TimeEntriesResult) + response = Models::Operations::HrisGetTimeEntriesResponse.new( status_code: http_response.status, content_type: content_type, raw_response: http_response, - time_off_policy_result: obj + time_entries_result: obj ) return response @@ -9235,19 +9235,19 @@ def get_time_off_policy(request, retries = nil, timeout_ms = nil) end - sig { params(request: T.nilable(Models::Operations::HrisGetTimeOffRequestRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::HrisGetTimeOffRequestResponse) } - def get_time_off_request(request, retries = nil, timeout_ms = nil) - # get_time_off_request - Get time off request + sig { params(request: T.nilable(Models::Operations::HrisGetTimeOffPolicyRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::HrisGetTimeOffPolicyResponse) } + def get_time_off_policy(request, retries = nil, timeout_ms = nil) + # get_time_off_policy - Get Time Off Policy url, params = @sdk_configuration.get_server_details base_url = Utils.template_url(url, params) url = Utils.generate_url( - Models::Operations::HrisGetTimeOffRequestRequest, + Models::Operations::HrisGetTimeOffPolicyRequest, base_url, - '/unified/hris/time_off/{id}', + '/unified/hris/time_off_policies/{id}', request ) headers = Utils.get_headers(request) - query_params = Utils.get_query_params(Models::Operations::HrisGetTimeOffRequestRequest, request) + query_params = Utils.get_query_params(Models::Operations::HrisGetTimeOffPolicyRequest, request) headers['Accept'] = 'application/json' headers['user-agent'] = @sdk_configuration.user_agent retries ||= @sdk_configuration.retry_config @@ -9275,7 +9275,7 @@ def get_time_off_request(request, retries = nil, timeout_ms = nil) hook_ctx = SDKHooks::HookContext.new( base_url: base_url, oauth2_scopes: [], - operation_id: 'hris_get_time_off_request', + operation_id: 'hris_get_time_off_policy', security_source: @sdk_configuration.security_source ) @@ -9332,12 +9332,12 @@ def get_time_off_request(request, retries = nil, timeout_ms = nil) ), response: http_response ) - obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::TimeOffResult) - response = Models::Operations::HrisGetTimeOffRequestResponse.new( + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::TimeOffPolicyResult) + response = Models::Operations::HrisGetTimeOffPolicyResponse.new( status_code: http_response.status, content_type: content_type, raw_response: http_response, - time_off_result: obj + time_off_policy_result: obj ) return response @@ -9511,21 +9511,19 @@ def get_time_off_request(request, retries = nil, timeout_ms = nil) end - sig { params(request: T.nilable(Models::Operations::HrisGetTimeOffTypeRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::HrisGetTimeOffTypeResponse) } - def get_time_off_type(request, retries = nil, timeout_ms = nil) - # get_time_off_type - Get time off type - # - # @deprecated method: This will be removed in a future release, please migrate away from it as soon as possible. + sig { params(request: T.nilable(Models::Operations::HrisGetTimeOffRequestRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::HrisGetTimeOffRequestResponse) } + def get_time_off_request(request, retries = nil, timeout_ms = nil) + # get_time_off_request - Get time off request url, params = @sdk_configuration.get_server_details base_url = Utils.template_url(url, params) url = Utils.generate_url( - Models::Operations::HrisGetTimeOffTypeRequest, + Models::Operations::HrisGetTimeOffRequestRequest, base_url, - '/unified/hris/time_off_types/{id}', + '/unified/hris/time_off/{id}', request ) headers = Utils.get_headers(request) - query_params = Utils.get_query_params(Models::Operations::HrisGetTimeOffTypeRequest, request) + query_params = Utils.get_query_params(Models::Operations::HrisGetTimeOffRequestRequest, request) headers['Accept'] = 'application/json' headers['user-agent'] = @sdk_configuration.user_agent retries ||= @sdk_configuration.retry_config @@ -9553,7 +9551,7 @@ def get_time_off_type(request, retries = nil, timeout_ms = nil) hook_ctx = SDKHooks::HookContext.new( base_url: base_url, oauth2_scopes: [], - operation_id: 'hris_get_time_off_type', + operation_id: 'hris_get_time_off_request', security_source: @sdk_configuration.security_source ) @@ -9610,12 +9608,12 @@ def get_time_off_type(request, retries = nil, timeout_ms = nil) ), response: http_response ) - obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::ReferenceResult) - response = Models::Operations::HrisGetTimeOffTypeResponse.new( + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::TimeOffResult) + response = Models::Operations::HrisGetTimeOffRequestResponse.new( status_code: http_response.status, content_type: content_type, raw_response: http_response, - reference_result: obj + time_off_result: obj ) return response @@ -9789,35 +9787,21 @@ def get_time_off_type(request, retries = nil, timeout_ms = nil) end - sig { params(hris_invite_employee_request_dto: Models::Shared::HrisInviteEmployeeRequestDto, id: ::String, x_account_id: ::String, retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::HrisInviteEmployeeResponse) } - def invite_employee(hris_invite_employee_request_dto, id, x_account_id, retries = nil, timeout_ms = nil) - # invite_employee - Invite Employee - request = Models::Operations::HrisInviteEmployeeRequest.new( - - hris_invite_employee_request_dto: hris_invite_employee_request_dto, - id: id, - x_account_id: x_account_id - ) + sig { params(request: T.nilable(Models::Operations::HrisGetTimeOffTypeRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::HrisGetTimeOffTypeResponse) } + def get_time_off_type(request, retries = nil, timeout_ms = nil) + # get_time_off_type - Get time off type + # + # @deprecated method: This will be removed in a future release, please migrate away from it as soon as possible. url, params = @sdk_configuration.get_server_details base_url = Utils.template_url(url, params) url = Utils.generate_url( - Models::Operations::HrisInviteEmployeeRequest, + Models::Operations::HrisGetTimeOffTypeRequest, base_url, - '/unified/hris/employees/{id}/invite', + '/unified/hris/time_off_types/{id}', request ) headers = Utils.get_headers(request) - req_content_type, data, form = Utils.serialize_request_body(request, :hris_invite_employee_request_dto, :json) - headers['content-type'] = req_content_type - raise StandardError, 'request body is required' if data.nil? && form.nil? - - if form - body = Utils.encode_form(form) - elsif Utils.match_content_type(req_content_type, 'application/x-www-form-urlencoded') - body = URI.encode_www_form(data) - else - body = data - end + query_params = Utils.get_query_params(Models::Operations::HrisGetTimeOffTypeRequest, request) headers['Accept'] = 'application/json' headers['user-agent'] = @sdk_configuration.user_agent retries ||= @sdk_configuration.retry_config @@ -9845,7 +9829,7 @@ def invite_employee(hris_invite_employee_request_dto, id, x_account_id, retries hook_ctx = SDKHooks::HookContext.new( base_url: base_url, oauth2_scopes: [], - operation_id: 'hris_invite_employee', + operation_id: 'hris_get_time_off_type', security_source: @sdk_configuration.security_source ) @@ -9854,10 +9838,10 @@ def invite_employee(hris_invite_employee_request_dto, id, x_account_id, retries begin - http_response = connection.post(url) do |req| - req.body = body + http_response = connection.get(url) do |req| req.headers.merge!(headers) req.options.timeout = timeout unless timeout.nil? + req.params = query_params Utils.configure_request_security(req, security) @sdk_configuration.hooks.before_request( @@ -9902,12 +9886,12 @@ def invite_employee(hris_invite_employee_request_dto, id, x_account_id, retries ), response: http_response ) - obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::InviteEmployeeResult) - response = Models::Operations::HrisInviteEmployeeResponse.new( + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::ReferenceResult) + response = Models::Operations::HrisGetTimeOffTypeResponse.new( status_code: http_response.status, content_type: content_type, raw_response: http_response, - invite_employee_result: obj + reference_result: obj ) return response @@ -10081,14 +10065,35 @@ def invite_employee(hris_invite_employee_request_dto, id, x_account_id, retries end - sig { params(request: T.nilable(Models::Operations::HrisListBenefitsRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::HrisListBenefitsResponse) } - def list_benefits(request, retries = nil, timeout_ms = nil) - # list_benefits - List benefits + sig { params(hris_invite_employee_request_dto: Models::Shared::HrisInviteEmployeeRequestDto, id: ::String, x_account_id: ::String, retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::HrisInviteEmployeeResponse) } + def invite_employee(hris_invite_employee_request_dto, id, x_account_id, retries = nil, timeout_ms = nil) + # invite_employee - Invite Employee + request = Models::Operations::HrisInviteEmployeeRequest.new( + + hris_invite_employee_request_dto: hris_invite_employee_request_dto, + id: id, + x_account_id: x_account_id + ) url, params = @sdk_configuration.get_server_details base_url = Utils.template_url(url, params) - url = "#{base_url}/unified/hris/benefits" + url = Utils.generate_url( + Models::Operations::HrisInviteEmployeeRequest, + base_url, + '/unified/hris/employees/{id}/invite', + request + ) headers = Utils.get_headers(request) - query_params = Utils.get_query_params(Models::Operations::HrisListBenefitsRequest, request) + req_content_type, data, form = Utils.serialize_request_body(request, :hris_invite_employee_request_dto, :json) + headers['content-type'] = req_content_type + raise StandardError, 'request body is required' if data.nil? && form.nil? + + if form + body = Utils.encode_form(form) + elsif Utils.match_content_type(req_content_type, 'application/x-www-form-urlencoded') + body = URI.encode_www_form(data) + else + body = data + end headers['Accept'] = 'application/json' headers['user-agent'] = @sdk_configuration.user_agent retries ||= @sdk_configuration.retry_config @@ -10116,7 +10121,7 @@ def list_benefits(request, retries = nil, timeout_ms = nil) hook_ctx = SDKHooks::HookContext.new( base_url: base_url, oauth2_scopes: [], - operation_id: 'hris_list_benefits', + operation_id: 'hris_invite_employee', security_source: @sdk_configuration.security_source ) @@ -10125,10 +10130,10 @@ def list_benefits(request, retries = nil, timeout_ms = nil) begin - http_response = connection.get(url) do |req| + http_response = connection.post(url) do |req| + req.body = body req.headers.merge!(headers) req.options.timeout = timeout unless timeout.nil? - req.params = query_params Utils.configure_request_security(req, security) @sdk_configuration.hooks.before_request( @@ -10173,12 +10178,12 @@ def list_benefits(request, retries = nil, timeout_ms = nil) ), response: http_response ) - obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::HRISBenefitsPaginated) - response = Models::Operations::HrisListBenefitsResponse.new( + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::InviteEmployeeResult) + response = Models::Operations::HrisInviteEmployeeResponse.new( status_code: http_response.status, content_type: content_type, raw_response: http_response, - hris_benefits_paginated: obj + invite_employee_result: obj ) return response @@ -10352,14 +10357,14 @@ def list_benefits(request, retries = nil, timeout_ms = nil) end - sig { params(request: T.nilable(Models::Operations::HrisListCompaniesRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::HrisListCompaniesResponse) } - def list_companies(request, retries = nil, timeout_ms = nil) - # list_companies - List Companies + sig { params(request: T.nilable(Models::Operations::HrisListBenefitsRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::HrisListBenefitsResponse) } + def list_benefits(request, retries = nil, timeout_ms = nil) + # list_benefits - List benefits url, params = @sdk_configuration.get_server_details base_url = Utils.template_url(url, params) - url = "#{base_url}/unified/hris/companies" + url = "#{base_url}/unified/hris/benefits" headers = Utils.get_headers(request) - query_params = Utils.get_query_params(Models::Operations::HrisListCompaniesRequest, request) + query_params = Utils.get_query_params(Models::Operations::HrisListBenefitsRequest, request) headers['Accept'] = 'application/json' headers['user-agent'] = @sdk_configuration.user_agent retries ||= @sdk_configuration.retry_config @@ -10387,7 +10392,7 @@ def list_companies(request, retries = nil, timeout_ms = nil) hook_ctx = SDKHooks::HookContext.new( base_url: base_url, oauth2_scopes: [], - operation_id: 'hris_list_companies', + operation_id: 'hris_list_benefits', security_source: @sdk_configuration.security_source ) @@ -10444,12 +10449,12 @@ def list_companies(request, retries = nil, timeout_ms = nil) ), response: http_response ) - obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::CompaniesPaginated) - response = Models::Operations::HrisListCompaniesResponse.new( + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::HRISBenefitsPaginated) + response = Models::Operations::HrisListBenefitsResponse.new( status_code: http_response.status, content_type: content_type, raw_response: http_response, - companies_paginated: obj + hris_benefits_paginated: obj ) return response @@ -10623,14 +10628,14 @@ def list_companies(request, retries = nil, timeout_ms = nil) end - sig { params(request: T.nilable(Models::Operations::HrisListCompaniesGroupsRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::HrisListCompaniesGroupsResponse) } - def list_companies_groups(request, retries = nil, timeout_ms = nil) - # list_companies_groups - List Companies Groups + sig { params(request: T.nilable(Models::Operations::HrisListCompaniesRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::HrisListCompaniesResponse) } + def list_companies(request, retries = nil, timeout_ms = nil) + # list_companies - List Companies url, params = @sdk_configuration.get_server_details base_url = Utils.template_url(url, params) - url = "#{base_url}/unified/hris/groups/companies" + url = "#{base_url}/unified/hris/companies" headers = Utils.get_headers(request) - query_params = Utils.get_query_params(Models::Operations::HrisListCompaniesGroupsRequest, request) + query_params = Utils.get_query_params(Models::Operations::HrisListCompaniesRequest, request) headers['Accept'] = 'application/json' headers['user-agent'] = @sdk_configuration.user_agent retries ||= @sdk_configuration.retry_config @@ -10658,7 +10663,7 @@ def list_companies_groups(request, retries = nil, timeout_ms = nil) hook_ctx = SDKHooks::HookContext.new( base_url: base_url, oauth2_scopes: [], - operation_id: 'hris_list_companies_groups', + operation_id: 'hris_list_companies', security_source: @sdk_configuration.security_source ) @@ -10716,7 +10721,7 @@ def list_companies_groups(request, retries = nil, timeout_ms = nil) response: http_response ) obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::CompaniesPaginated) - response = Models::Operations::HrisListCompaniesGroupsResponse.new( + response = Models::Operations::HrisListCompaniesResponse.new( status_code: http_response.status, content_type: content_type, raw_response: http_response, @@ -10894,14 +10899,14 @@ def list_companies_groups(request, retries = nil, timeout_ms = nil) end - sig { params(request: T.nilable(Models::Operations::HrisListCostCenterGroupsRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::HrisListCostCenterGroupsResponse) } - def list_cost_center_groups(request, retries = nil, timeout_ms = nil) - # list_cost_center_groups - List Cost Center Groups + sig { params(request: T.nilable(Models::Operations::HrisListCompaniesGroupsRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::HrisListCompaniesGroupsResponse) } + def list_companies_groups(request, retries = nil, timeout_ms = nil) + # list_companies_groups - List Companies Groups url, params = @sdk_configuration.get_server_details base_url = Utils.template_url(url, params) - url = "#{base_url}/unified/hris/groups/cost_centers" + url = "#{base_url}/unified/hris/groups/companies" headers = Utils.get_headers(request) - query_params = Utils.get_query_params(Models::Operations::HrisListCostCenterGroupsRequest, request) + query_params = Utils.get_query_params(Models::Operations::HrisListCompaniesGroupsRequest, request) headers['Accept'] = 'application/json' headers['user-agent'] = @sdk_configuration.user_agent retries ||= @sdk_configuration.retry_config @@ -10929,7 +10934,7 @@ def list_cost_center_groups(request, retries = nil, timeout_ms = nil) hook_ctx = SDKHooks::HookContext.new( base_url: base_url, oauth2_scopes: [], - operation_id: 'hris_list_cost_center_groups', + operation_id: 'hris_list_companies_groups', security_source: @sdk_configuration.security_source ) @@ -10986,12 +10991,12 @@ def list_cost_center_groups(request, retries = nil, timeout_ms = nil) ), response: http_response ) - obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::HRISCostCenterPaginated) - response = Models::Operations::HrisListCostCenterGroupsResponse.new( + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::CompaniesPaginated) + response = Models::Operations::HrisListCompaniesGroupsResponse.new( status_code: http_response.status, content_type: content_type, raw_response: http_response, - hris_cost_center_paginated: obj + companies_paginated: obj ) return response @@ -11165,14 +11170,556 @@ def list_cost_center_groups(request, retries = nil, timeout_ms = nil) end - sig { params(request: T.nilable(Models::Operations::HrisListDepartmentGroupsRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::HrisListDepartmentGroupsResponse) } - def list_department_groups(request, retries = nil, timeout_ms = nil) - # list_department_groups - List Department Groups + sig { params(request: T.nilable(Models::Operations::HrisListCostCenterGroupsRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::HrisListCostCenterGroupsResponse) } + def list_cost_center_groups(request, retries = nil, timeout_ms = nil) + # list_cost_center_groups - List Cost Center Groups url, params = @sdk_configuration.get_server_details base_url = Utils.template_url(url, params) - url = "#{base_url}/unified/hris/groups/departments" + url = "#{base_url}/unified/hris/groups/cost_centers" headers = Utils.get_headers(request) - query_params = Utils.get_query_params(Models::Operations::HrisListDepartmentGroupsRequest, request) + query_params = Utils.get_query_params(Models::Operations::HrisListCostCenterGroupsRequest, request) + headers['Accept'] = 'application/json' + headers['user-agent'] = @sdk_configuration.user_agent + retries ||= @sdk_configuration.retry_config + retries ||= Utils::RetryConfig.new( + backoff: Utils::BackoffStrategy.new( + exponent: 1.5, + initial_interval: 500, + max_elapsed_time: 3_600_000, + max_interval: 60_000 + ), + retry_connection_errors: true, + strategy: 'backoff' + ) + retry_options = retries.to_faraday_retry_options(initial_time: Time.now) + retry_options[:retry_statuses] = [429, 408] + + security = !@sdk_configuration.nil? && !@sdk_configuration.security_source.nil? ? @sdk_configuration.security_source.call : nil + + timeout = (timeout_ms.to_f / 1000) unless timeout_ms.nil? + timeout ||= @sdk_configuration.timeout + + connection = @sdk_configuration.client.dup + connection.request :retry, retry_options + + hook_ctx = SDKHooks::HookContext.new( + base_url: base_url, + oauth2_scopes: [], + operation_id: 'hris_list_cost_center_groups', + security_source: @sdk_configuration.security_source + ) + + error = T.let(nil, T.nilable(StandardError)) + http_response = T.let(nil, T.nilable(Faraday::Response)) + + + begin + http_response = connection.get(url) do |req| + req.headers.merge!(headers) + req.options.timeout = timeout unless timeout.nil? + req.params = query_params + Utils.configure_request_security(req, security) + + @sdk_configuration.hooks.before_request( + hook_ctx: SDKHooks::BeforeRequestHookContext.new( + hook_ctx: hook_ctx + ), + request: req + ) + end + rescue StandardError => e + error = e + ensure + if http_response.nil? || Utils.error_status?(http_response.status) + http_response = @sdk_configuration.hooks.after_error( + error: error, + hook_ctx: SDKHooks::AfterErrorHookContext.new( + hook_ctx: hook_ctx + ), + response: http_response + ) + else + http_response = @sdk_configuration.hooks.after_success( + hook_ctx: SDKHooks::AfterSuccessHookContext.new( + hook_ctx: hook_ctx + ), + response: http_response + ) + end + + if http_response.nil? + raise error if !error.nil? + raise 'no response' + end + end + + content_type = http_response.headers.fetch('Content-Type', 'application/octet-stream') + if Utils.match_status_code(http_response.status, ['200']) + if Utils.match_content_type(content_type, 'application/json') + http_response = @sdk_configuration.hooks.after_success( + hook_ctx: SDKHooks::AfterSuccessHookContext.new( + hook_ctx: hook_ctx + ), + response: http_response + ) + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::HRISCostCenterPaginated) + response = Models::Operations::HrisListCostCenterGroupsResponse.new( + status_code: http_response.status, + content_type: content_type, + raw_response: http_response, + hris_cost_center_paginated: obj + ) + + return response + else + raise ::StackOne::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'Unknown content type received' + end + elsif Utils.match_status_code(http_response.status, ['400']) + if Utils.match_content_type(content_type, 'application/json') + http_response = @sdk_configuration.hooks.after_success( + hook_ctx: SDKHooks::AfterSuccessHookContext.new( + hook_ctx: hook_ctx + ), + response: http_response + ) + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Errors::BadRequestResponse) + throw obj + else + raise ::StackOne::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'Unknown content type received' + end + elsif Utils.match_status_code(http_response.status, ['401']) + if Utils.match_content_type(content_type, 'application/json') + http_response = @sdk_configuration.hooks.after_success( + hook_ctx: SDKHooks::AfterSuccessHookContext.new( + hook_ctx: hook_ctx + ), + response: http_response + ) + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Errors::UnauthorizedResponse) + throw obj + else + raise ::StackOne::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'Unknown content type received' + end + elsif Utils.match_status_code(http_response.status, ['403']) + if Utils.match_content_type(content_type, 'application/json') + http_response = @sdk_configuration.hooks.after_success( + hook_ctx: SDKHooks::AfterSuccessHookContext.new( + hook_ctx: hook_ctx + ), + response: http_response + ) + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Errors::ForbiddenResponse) + throw obj + else + raise ::StackOne::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'Unknown content type received' + end + elsif Utils.match_status_code(http_response.status, ['404']) + if Utils.match_content_type(content_type, 'application/json') + http_response = @sdk_configuration.hooks.after_success( + hook_ctx: SDKHooks::AfterSuccessHookContext.new( + hook_ctx: hook_ctx + ), + response: http_response + ) + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Errors::NotFoundResponse) + throw obj + else + raise ::StackOne::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'Unknown content type received' + end + elsif Utils.match_status_code(http_response.status, ['408']) + if Utils.match_content_type(content_type, 'application/json') + http_response = @sdk_configuration.hooks.after_success( + hook_ctx: SDKHooks::AfterSuccessHookContext.new( + hook_ctx: hook_ctx + ), + response: http_response + ) + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Errors::RequestTimedOutResponse) + throw obj + else + raise ::StackOne::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'Unknown content type received' + end + elsif Utils.match_status_code(http_response.status, ['409']) + if Utils.match_content_type(content_type, 'application/json') + http_response = @sdk_configuration.hooks.after_success( + hook_ctx: SDKHooks::AfterSuccessHookContext.new( + hook_ctx: hook_ctx + ), + response: http_response + ) + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Errors::ConflictResponse) + throw obj + else + raise ::StackOne::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'Unknown content type received' + end + elsif Utils.match_status_code(http_response.status, ['412']) + if Utils.match_content_type(content_type, 'application/json') + http_response = @sdk_configuration.hooks.after_success( + hook_ctx: SDKHooks::AfterSuccessHookContext.new( + hook_ctx: hook_ctx + ), + response: http_response + ) + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Errors::PreconditionFailedResponse) + throw obj + else + raise ::StackOne::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'Unknown content type received' + end + elsif Utils.match_status_code(http_response.status, ['422']) + if Utils.match_content_type(content_type, 'application/json') + http_response = @sdk_configuration.hooks.after_success( + hook_ctx: SDKHooks::AfterSuccessHookContext.new( + hook_ctx: hook_ctx + ), + response: http_response + ) + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Errors::UnprocessableEntityResponse) + throw obj + else + raise ::StackOne::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'Unknown content type received' + end + elsif Utils.match_status_code(http_response.status, ['429']) + if Utils.match_content_type(content_type, 'application/json') + http_response = @sdk_configuration.hooks.after_success( + hook_ctx: SDKHooks::AfterSuccessHookContext.new( + hook_ctx: hook_ctx + ), + response: http_response + ) + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Errors::TooManyRequestsResponse) + throw obj + else + raise ::StackOne::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'Unknown content type received' + end + elsif Utils.match_status_code(http_response.status, ['500']) + if Utils.match_content_type(content_type, 'application/json') + http_response = @sdk_configuration.hooks.after_success( + hook_ctx: SDKHooks::AfterSuccessHookContext.new( + hook_ctx: hook_ctx + ), + response: http_response + ) + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Errors::InternalServerErrorResponse) + throw obj + else + raise ::StackOne::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'Unknown content type received' + end + elsif Utils.match_status_code(http_response.status, ['501']) + if Utils.match_content_type(content_type, 'application/json') + http_response = @sdk_configuration.hooks.after_success( + hook_ctx: SDKHooks::AfterSuccessHookContext.new( + hook_ctx: hook_ctx + ), + response: http_response + ) + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Errors::NotImplementedResponse) + throw obj + else + raise ::StackOne::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'Unknown content type received' + end + elsif Utils.match_status_code(http_response.status, ['502']) + if Utils.match_content_type(content_type, 'application/json') + http_response = @sdk_configuration.hooks.after_success( + hook_ctx: SDKHooks::AfterSuccessHookContext.new( + hook_ctx: hook_ctx + ), + response: http_response + ) + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Errors::BadGatewayResponse) + throw obj + else + raise ::StackOne::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'Unknown content type received' + end + elsif Utils.match_status_code(http_response.status, ['4XX']) + raise ::StackOne::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'API error occurred' + elsif Utils.match_status_code(http_response.status, ['5XX']) + raise ::StackOne::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'API error occurred' + else + raise ::StackOne::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'Unknown status code received' + + end + end + + + sig { params(request: T.nilable(Models::Operations::HrisListDepartmentGroupsRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::HrisListDepartmentGroupsResponse) } + def list_department_groups(request, retries = nil, timeout_ms = nil) + # list_department_groups - List Department Groups + url, params = @sdk_configuration.get_server_details + base_url = Utils.template_url(url, params) + url = "#{base_url}/unified/hris/groups/departments" + headers = Utils.get_headers(request) + query_params = Utils.get_query_params(Models::Operations::HrisListDepartmentGroupsRequest, request) + headers['Accept'] = 'application/json' + headers['user-agent'] = @sdk_configuration.user_agent + retries ||= @sdk_configuration.retry_config + retries ||= Utils::RetryConfig.new( + backoff: Utils::BackoffStrategy.new( + exponent: 1.5, + initial_interval: 500, + max_elapsed_time: 3_600_000, + max_interval: 60_000 + ), + retry_connection_errors: true, + strategy: 'backoff' + ) + retry_options = retries.to_faraday_retry_options(initial_time: Time.now) + retry_options[:retry_statuses] = [429, 408] + + security = !@sdk_configuration.nil? && !@sdk_configuration.security_source.nil? ? @sdk_configuration.security_source.call : nil + + timeout = (timeout_ms.to_f / 1000) unless timeout_ms.nil? + timeout ||= @sdk_configuration.timeout + + connection = @sdk_configuration.client.dup + connection.request :retry, retry_options + + hook_ctx = SDKHooks::HookContext.new( + base_url: base_url, + oauth2_scopes: [], + operation_id: 'hris_list_department_groups', + security_source: @sdk_configuration.security_source + ) + + error = T.let(nil, T.nilable(StandardError)) + http_response = T.let(nil, T.nilable(Faraday::Response)) + + + begin + http_response = connection.get(url) do |req| + req.headers.merge!(headers) + req.options.timeout = timeout unless timeout.nil? + req.params = query_params + Utils.configure_request_security(req, security) + + @sdk_configuration.hooks.before_request( + hook_ctx: SDKHooks::BeforeRequestHookContext.new( + hook_ctx: hook_ctx + ), + request: req + ) + end + rescue StandardError => e + error = e + ensure + if http_response.nil? || Utils.error_status?(http_response.status) + http_response = @sdk_configuration.hooks.after_error( + error: error, + hook_ctx: SDKHooks::AfterErrorHookContext.new( + hook_ctx: hook_ctx + ), + response: http_response + ) + else + http_response = @sdk_configuration.hooks.after_success( + hook_ctx: SDKHooks::AfterSuccessHookContext.new( + hook_ctx: hook_ctx + ), + response: http_response + ) + end + + if http_response.nil? + raise error if !error.nil? + raise 'no response' + end + end + + content_type = http_response.headers.fetch('Content-Type', 'application/octet-stream') + if Utils.match_status_code(http_response.status, ['200']) + if Utils.match_content_type(content_type, 'application/json') + http_response = @sdk_configuration.hooks.after_success( + hook_ctx: SDKHooks::AfterSuccessHookContext.new( + hook_ctx: hook_ctx + ), + response: http_response + ) + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::HRISDepartmentsPaginated) + response = Models::Operations::HrisListDepartmentGroupsResponse.new( + status_code: http_response.status, + content_type: content_type, + raw_response: http_response, + hris_departments_paginated: obj + ) + + return response + else + raise ::StackOne::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'Unknown content type received' + end + elsif Utils.match_status_code(http_response.status, ['400']) + if Utils.match_content_type(content_type, 'application/json') + http_response = @sdk_configuration.hooks.after_success( + hook_ctx: SDKHooks::AfterSuccessHookContext.new( + hook_ctx: hook_ctx + ), + response: http_response + ) + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Errors::BadRequestResponse) + throw obj + else + raise ::StackOne::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'Unknown content type received' + end + elsif Utils.match_status_code(http_response.status, ['401']) + if Utils.match_content_type(content_type, 'application/json') + http_response = @sdk_configuration.hooks.after_success( + hook_ctx: SDKHooks::AfterSuccessHookContext.new( + hook_ctx: hook_ctx + ), + response: http_response + ) + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Errors::UnauthorizedResponse) + throw obj + else + raise ::StackOne::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'Unknown content type received' + end + elsif Utils.match_status_code(http_response.status, ['403']) + if Utils.match_content_type(content_type, 'application/json') + http_response = @sdk_configuration.hooks.after_success( + hook_ctx: SDKHooks::AfterSuccessHookContext.new( + hook_ctx: hook_ctx + ), + response: http_response + ) + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Errors::ForbiddenResponse) + throw obj + else + raise ::StackOne::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'Unknown content type received' + end + elsif Utils.match_status_code(http_response.status, ['404']) + if Utils.match_content_type(content_type, 'application/json') + http_response = @sdk_configuration.hooks.after_success( + hook_ctx: SDKHooks::AfterSuccessHookContext.new( + hook_ctx: hook_ctx + ), + response: http_response + ) + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Errors::NotFoundResponse) + throw obj + else + raise ::StackOne::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'Unknown content type received' + end + elsif Utils.match_status_code(http_response.status, ['408']) + if Utils.match_content_type(content_type, 'application/json') + http_response = @sdk_configuration.hooks.after_success( + hook_ctx: SDKHooks::AfterSuccessHookContext.new( + hook_ctx: hook_ctx + ), + response: http_response + ) + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Errors::RequestTimedOutResponse) + throw obj + else + raise ::StackOne::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'Unknown content type received' + end + elsif Utils.match_status_code(http_response.status, ['409']) + if Utils.match_content_type(content_type, 'application/json') + http_response = @sdk_configuration.hooks.after_success( + hook_ctx: SDKHooks::AfterSuccessHookContext.new( + hook_ctx: hook_ctx + ), + response: http_response + ) + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Errors::ConflictResponse) + throw obj + else + raise ::StackOne::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'Unknown content type received' + end + elsif Utils.match_status_code(http_response.status, ['412']) + if Utils.match_content_type(content_type, 'application/json') + http_response = @sdk_configuration.hooks.after_success( + hook_ctx: SDKHooks::AfterSuccessHookContext.new( + hook_ctx: hook_ctx + ), + response: http_response + ) + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Errors::PreconditionFailedResponse) + throw obj + else + raise ::StackOne::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'Unknown content type received' + end + elsif Utils.match_status_code(http_response.status, ['422']) + if Utils.match_content_type(content_type, 'application/json') + http_response = @sdk_configuration.hooks.after_success( + hook_ctx: SDKHooks::AfterSuccessHookContext.new( + hook_ctx: hook_ctx + ), + response: http_response + ) + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Errors::UnprocessableEntityResponse) + throw obj + else + raise ::StackOne::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'Unknown content type received' + end + elsif Utils.match_status_code(http_response.status, ['429']) + if Utils.match_content_type(content_type, 'application/json') + http_response = @sdk_configuration.hooks.after_success( + hook_ctx: SDKHooks::AfterSuccessHookContext.new( + hook_ctx: hook_ctx + ), + response: http_response + ) + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Errors::TooManyRequestsResponse) + throw obj + else + raise ::StackOne::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'Unknown content type received' + end + elsif Utils.match_status_code(http_response.status, ['500']) + if Utils.match_content_type(content_type, 'application/json') + http_response = @sdk_configuration.hooks.after_success( + hook_ctx: SDKHooks::AfterSuccessHookContext.new( + hook_ctx: hook_ctx + ), + response: http_response + ) + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Errors::InternalServerErrorResponse) + throw obj + else + raise ::StackOne::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'Unknown content type received' + end + elsif Utils.match_status_code(http_response.status, ['501']) + if Utils.match_content_type(content_type, 'application/json') + http_response = @sdk_configuration.hooks.after_success( + hook_ctx: SDKHooks::AfterSuccessHookContext.new( + hook_ctx: hook_ctx + ), + response: http_response + ) + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Errors::NotImplementedResponse) + throw obj + else + raise ::StackOne::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'Unknown content type received' + end + elsif Utils.match_status_code(http_response.status, ['502']) + if Utils.match_content_type(content_type, 'application/json') + http_response = @sdk_configuration.hooks.after_success( + hook_ctx: SDKHooks::AfterSuccessHookContext.new( + hook_ctx: hook_ctx + ), + response: http_response + ) + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Errors::BadGatewayResponse) + throw obj + else + raise ::StackOne::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'Unknown content type received' + end + elsif Utils.match_status_code(http_response.status, ['4XX']) + raise ::StackOne::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'API error occurred' + elsif Utils.match_status_code(http_response.status, ['5XX']) + raise ::StackOne::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'API error occurred' + else + raise ::StackOne::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'Unknown status code received' + + end + end + + + sig { params(request: T.nilable(Models::Operations::HrisListDivisionGroupsRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::HrisListDivisionGroupsResponse) } + def list_division_groups(request, retries = nil, timeout_ms = nil) + # list_division_groups - List Division Groups + url, params = @sdk_configuration.get_server_details + base_url = Utils.template_url(url, params) + url = "#{base_url}/unified/hris/groups/divisions" + headers = Utils.get_headers(request) + query_params = Utils.get_query_params(Models::Operations::HrisListDivisionGroupsRequest, request) headers['Accept'] = 'application/json' headers['user-agent'] = @sdk_configuration.user_agent retries ||= @sdk_configuration.retry_config @@ -11200,7 +11747,7 @@ def list_department_groups(request, retries = nil, timeout_ms = nil) hook_ctx = SDKHooks::HookContext.new( base_url: base_url, oauth2_scopes: [], - operation_id: 'hris_list_department_groups', + operation_id: 'hris_list_division_groups', security_source: @sdk_configuration.security_source ) @@ -11257,12 +11804,12 @@ def list_department_groups(request, retries = nil, timeout_ms = nil) ), response: http_response ) - obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::HRISDepartmentsPaginated) - response = Models::Operations::HrisListDepartmentGroupsResponse.new( + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::HRISDivisionsPaginated) + response = Models::Operations::HrisListDivisionGroupsResponse.new( status_code: http_response.status, content_type: content_type, raw_response: http_response, - hris_departments_paginated: obj + hris_divisions_paginated: obj ) return response @@ -11436,14 +11983,14 @@ def list_department_groups(request, retries = nil, timeout_ms = nil) end - sig { params(request: T.nilable(Models::Operations::HrisListDivisionGroupsRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::HrisListDivisionGroupsResponse) } - def list_division_groups(request, retries = nil, timeout_ms = nil) - # list_division_groups - List Division Groups + sig { params(request: T.nilable(Models::Operations::HrisListEmployeeCategoriesRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::HrisListEmployeeCategoriesResponse) } + def list_employee_categories(request, retries = nil, timeout_ms = nil) + # list_employee_categories - List Employee Document Categories url, params = @sdk_configuration.get_server_details base_url = Utils.template_url(url, params) - url = "#{base_url}/unified/hris/groups/divisions" + url = "#{base_url}/unified/hris/documents/employee_categories" headers = Utils.get_headers(request) - query_params = Utils.get_query_params(Models::Operations::HrisListDivisionGroupsRequest, request) + query_params = Utils.get_query_params(Models::Operations::HrisListEmployeeCategoriesRequest, request) headers['Accept'] = 'application/json' headers['user-agent'] = @sdk_configuration.user_agent retries ||= @sdk_configuration.retry_config @@ -11471,7 +12018,7 @@ def list_division_groups(request, retries = nil, timeout_ms = nil) hook_ctx = SDKHooks::HookContext.new( base_url: base_url, oauth2_scopes: [], - operation_id: 'hris_list_division_groups', + operation_id: 'hris_list_employee_categories', security_source: @sdk_configuration.security_source ) @@ -11528,12 +12075,12 @@ def list_division_groups(request, retries = nil, timeout_ms = nil) ), response: http_response ) - obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::HRISDivisionsPaginated) - response = Models::Operations::HrisListDivisionGroupsResponse.new( + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::ReferencePaginated) + response = Models::Operations::HrisListEmployeeCategoriesResponse.new( status_code: http_response.status, content_type: content_type, raw_response: http_response, - hris_divisions_paginated: obj + reference_paginated: obj ) return response @@ -11707,14 +12254,14 @@ def list_division_groups(request, retries = nil, timeout_ms = nil) end - sig { params(request: T.nilable(Models::Operations::HrisListEmployeeCategoriesRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::HrisListEmployeeCategoriesResponse) } - def list_employee_categories(request, retries = nil, timeout_ms = nil) - # list_employee_categories - List Employee Document Categories + sig { params(request: T.nilable(Models::Operations::HrisListEmployeeCustomFieldDefinitionsRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::HrisListEmployeeCustomFieldDefinitionsResponse) } + def list_employee_custom_field_definitions(request, retries = nil, timeout_ms = nil) + # list_employee_custom_field_definitions - List employee Custom Field Definitions url, params = @sdk_configuration.get_server_details base_url = Utils.template_url(url, params) - url = "#{base_url}/unified/hris/documents/employee_categories" + url = "#{base_url}/unified/hris/custom_field_definitions/employees" headers = Utils.get_headers(request) - query_params = Utils.get_query_params(Models::Operations::HrisListEmployeeCategoriesRequest, request) + query_params = Utils.get_query_params(Models::Operations::HrisListEmployeeCustomFieldDefinitionsRequest, request) headers['Accept'] = 'application/json' headers['user-agent'] = @sdk_configuration.user_agent retries ||= @sdk_configuration.retry_config @@ -11742,7 +12289,7 @@ def list_employee_categories(request, retries = nil, timeout_ms = nil) hook_ctx = SDKHooks::HookContext.new( base_url: base_url, oauth2_scopes: [], - operation_id: 'hris_list_employee_categories', + operation_id: 'hris_list_employee_custom_field_definitions', security_source: @sdk_configuration.security_source ) @@ -11799,12 +12346,12 @@ def list_employee_categories(request, retries = nil, timeout_ms = nil) ), response: http_response ) - obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::ReferencePaginated) - response = Models::Operations::HrisListEmployeeCategoriesResponse.new( + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::CustomFieldDefinitionsPaginated) + response = Models::Operations::HrisListEmployeeCustomFieldDefinitionsResponse.new( status_code: http_response.status, content_type: content_type, raw_response: http_response, - reference_paginated: obj + custom_field_definitions_paginated: obj ) return response @@ -11978,14 +12525,19 @@ def list_employee_categories(request, retries = nil, timeout_ms = nil) end - sig { params(request: T.nilable(Models::Operations::HrisListEmployeeCustomFieldDefinitionsRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::HrisListEmployeeCustomFieldDefinitionsResponse) } - def list_employee_custom_field_definitions(request, retries = nil, timeout_ms = nil) - # list_employee_custom_field_definitions - List employee Custom Field Definitions + sig { params(request: T.nilable(Models::Operations::HrisListEmployeeDocumentsRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::HrisListEmployeeDocumentsResponse) } + def list_employee_documents(request, retries = nil, timeout_ms = nil) + # list_employee_documents - List Employee Documents url, params = @sdk_configuration.get_server_details base_url = Utils.template_url(url, params) - url = "#{base_url}/unified/hris/custom_field_definitions/employees" + url = Utils.generate_url( + Models::Operations::HrisListEmployeeDocumentsRequest, + base_url, + '/unified/hris/employees/{id}/documents', + request + ) headers = Utils.get_headers(request) - query_params = Utils.get_query_params(Models::Operations::HrisListEmployeeCustomFieldDefinitionsRequest, request) + query_params = Utils.get_query_params(Models::Operations::HrisListEmployeeDocumentsRequest, request) headers['Accept'] = 'application/json' headers['user-agent'] = @sdk_configuration.user_agent retries ||= @sdk_configuration.retry_config @@ -12013,7 +12565,7 @@ def list_employee_custom_field_definitions(request, retries = nil, timeout_ms = hook_ctx = SDKHooks::HookContext.new( base_url: base_url, oauth2_scopes: [], - operation_id: 'hris_list_employee_custom_field_definitions', + operation_id: 'hris_list_employee_documents', security_source: @sdk_configuration.security_source ) @@ -12070,12 +12622,12 @@ def list_employee_custom_field_definitions(request, retries = nil, timeout_ms = ), response: http_response ) - obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::CustomFieldDefinitionsPaginated) - response = Models::Operations::HrisListEmployeeCustomFieldDefinitionsResponse.new( + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::HrisDocumentsPaginated) + response = Models::Operations::HrisListEmployeeDocumentsResponse.new( status_code: http_response.status, content_type: content_type, raw_response: http_response, - custom_field_definitions_paginated: obj + hris_documents_paginated: obj ) return response @@ -12249,19 +12801,19 @@ def list_employee_custom_field_definitions(request, retries = nil, timeout_ms = end - sig { params(request: T.nilable(Models::Operations::HrisListEmployeeDocumentsRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::HrisListEmployeeDocumentsResponse) } - def list_employee_documents(request, retries = nil, timeout_ms = nil) - # list_employee_documents - List Employee Documents + sig { params(request: T.nilable(Models::Operations::HrisListEmployeeEmploymentsRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::HrisListEmployeeEmploymentsResponse) } + def list_employee_employments(request, retries = nil, timeout_ms = nil) + # list_employee_employments - List Employee Employments url, params = @sdk_configuration.get_server_details base_url = Utils.template_url(url, params) url = Utils.generate_url( - Models::Operations::HrisListEmployeeDocumentsRequest, + Models::Operations::HrisListEmployeeEmploymentsRequest, base_url, - '/unified/hris/employees/{id}/documents', + '/unified/hris/employees/{id}/employments', request ) headers = Utils.get_headers(request) - query_params = Utils.get_query_params(Models::Operations::HrisListEmployeeDocumentsRequest, request) + query_params = Utils.get_query_params(Models::Operations::HrisListEmployeeEmploymentsRequest, request) headers['Accept'] = 'application/json' headers['user-agent'] = @sdk_configuration.user_agent retries ||= @sdk_configuration.retry_config @@ -12289,7 +12841,7 @@ def list_employee_documents(request, retries = nil, timeout_ms = nil) hook_ctx = SDKHooks::HookContext.new( base_url: base_url, oauth2_scopes: [], - operation_id: 'hris_list_employee_documents', + operation_id: 'hris_list_employee_employments', security_source: @sdk_configuration.security_source ) @@ -12346,12 +12898,12 @@ def list_employee_documents(request, retries = nil, timeout_ms = nil) ), response: http_response ) - obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::HrisDocumentsPaginated) - response = Models::Operations::HrisListEmployeeDocumentsResponse.new( + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::EmploymentsPaginated) + response = Models::Operations::HrisListEmployeeEmploymentsResponse.new( status_code: http_response.status, content_type: content_type, raw_response: http_response, - hris_documents_paginated: obj + employments_paginated: obj ) return response @@ -12525,19 +13077,19 @@ def list_employee_documents(request, retries = nil, timeout_ms = nil) end - sig { params(request: T.nilable(Models::Operations::HrisListEmployeeEmploymentsRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::HrisListEmployeeEmploymentsResponse) } - def list_employee_employments(request, retries = nil, timeout_ms = nil) - # list_employee_employments - List Employee Employments + sig { params(request: T.nilable(Models::Operations::HrisListEmployeeSkillsRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::HrisListEmployeeSkillsResponse) } + def list_employee_skills(request, retries = nil, timeout_ms = nil) + # list_employee_skills - List Employee Skills url, params = @sdk_configuration.get_server_details base_url = Utils.template_url(url, params) url = Utils.generate_url( - Models::Operations::HrisListEmployeeEmploymentsRequest, + Models::Operations::HrisListEmployeeSkillsRequest, base_url, - '/unified/hris/employees/{id}/employments', + '/unified/hris/employees/{id}/skills', request ) headers = Utils.get_headers(request) - query_params = Utils.get_query_params(Models::Operations::HrisListEmployeeEmploymentsRequest, request) + query_params = Utils.get_query_params(Models::Operations::HrisListEmployeeSkillsRequest, request) headers['Accept'] = 'application/json' headers['user-agent'] = @sdk_configuration.user_agent retries ||= @sdk_configuration.retry_config @@ -12565,7 +13117,7 @@ def list_employee_employments(request, retries = nil, timeout_ms = nil) hook_ctx = SDKHooks::HookContext.new( base_url: base_url, oauth2_scopes: [], - operation_id: 'hris_list_employee_employments', + operation_id: 'hris_list_employee_skills', security_source: @sdk_configuration.security_source ) @@ -12622,12 +13174,12 @@ def list_employee_employments(request, retries = nil, timeout_ms = nil) ), response: http_response ) - obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::EmploymentsPaginated) - response = Models::Operations::HrisListEmployeeEmploymentsResponse.new( + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::EntitySkillsPaginated) + response = Models::Operations::HrisListEmployeeSkillsResponse.new( status_code: http_response.status, content_type: content_type, raw_response: http_response, - employments_paginated: obj + entity_skills_paginated: obj ) return response @@ -12801,19 +13353,19 @@ def list_employee_employments(request, retries = nil, timeout_ms = nil) end - sig { params(request: T.nilable(Models::Operations::HrisListEmployeeSkillsRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::HrisListEmployeeSkillsResponse) } - def list_employee_skills(request, retries = nil, timeout_ms = nil) - # list_employee_skills - List Employee Skills + sig { params(request: T.nilable(Models::Operations::HrisListEmployeeTasksRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::HrisListEmployeeTasksResponse) } + def list_employee_tasks(request, retries = nil, timeout_ms = nil) + # list_employee_tasks - List Employee Tasks url, params = @sdk_configuration.get_server_details base_url = Utils.template_url(url, params) url = Utils.generate_url( - Models::Operations::HrisListEmployeeSkillsRequest, + Models::Operations::HrisListEmployeeTasksRequest, base_url, - '/unified/hris/employees/{id}/skills', + '/unified/hris/employees/{id}/tasks', request ) headers = Utils.get_headers(request) - query_params = Utils.get_query_params(Models::Operations::HrisListEmployeeSkillsRequest, request) + query_params = Utils.get_query_params(Models::Operations::HrisListEmployeeTasksRequest, request) headers['Accept'] = 'application/json' headers['user-agent'] = @sdk_configuration.user_agent retries ||= @sdk_configuration.retry_config @@ -12841,7 +13393,7 @@ def list_employee_skills(request, retries = nil, timeout_ms = nil) hook_ctx = SDKHooks::HookContext.new( base_url: base_url, oauth2_scopes: [], - operation_id: 'hris_list_employee_skills', + operation_id: 'hris_list_employee_tasks', security_source: @sdk_configuration.security_source ) @@ -12898,12 +13450,12 @@ def list_employee_skills(request, retries = nil, timeout_ms = nil) ), response: http_response ) - obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::EntitySkillsPaginated) - response = Models::Operations::HrisListEmployeeSkillsResponse.new( + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::TasksPaginated) + response = Models::Operations::HrisListEmployeeTasksResponse.new( status_code: http_response.status, content_type: content_type, raw_response: http_response, - entity_skills_paginated: obj + tasks_paginated: obj ) return response @@ -13077,19 +13629,19 @@ def list_employee_skills(request, retries = nil, timeout_ms = nil) end - sig { params(request: T.nilable(Models::Operations::HrisListEmployeeTasksRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::HrisListEmployeeTasksResponse) } - def list_employee_tasks(request, retries = nil, timeout_ms = nil) - # list_employee_tasks - List Employee Tasks + sig { params(request: T.nilable(Models::Operations::HrisListEmployeeTimeOffBalancesRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::HrisListEmployeeTimeOffBalancesResponse) } + def list_employee_time_off_balances(request, retries = nil, timeout_ms = nil) + # list_employee_time_off_balances - List Employee Time Off Balances url, params = @sdk_configuration.get_server_details base_url = Utils.template_url(url, params) url = Utils.generate_url( - Models::Operations::HrisListEmployeeTasksRequest, + Models::Operations::HrisListEmployeeTimeOffBalancesRequest, base_url, - '/unified/hris/employees/{id}/tasks', + '/unified/hris/employees/{id}/time_off_balances', request ) headers = Utils.get_headers(request) - query_params = Utils.get_query_params(Models::Operations::HrisListEmployeeTasksRequest, request) + query_params = Utils.get_query_params(Models::Operations::HrisListEmployeeTimeOffBalancesRequest, request) headers['Accept'] = 'application/json' headers['user-agent'] = @sdk_configuration.user_agent retries ||= @sdk_configuration.retry_config @@ -13117,7 +13669,7 @@ def list_employee_tasks(request, retries = nil, timeout_ms = nil) hook_ctx = SDKHooks::HookContext.new( base_url: base_url, oauth2_scopes: [], - operation_id: 'hris_list_employee_tasks', + operation_id: 'hris_list_employee_time_off_balances', security_source: @sdk_configuration.security_source ) @@ -13174,12 +13726,12 @@ def list_employee_tasks(request, retries = nil, timeout_ms = nil) ), response: http_response ) - obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::TasksPaginated) - response = Models::Operations::HrisListEmployeeTasksResponse.new( + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::TimeOffBalancesPaginated) + response = Models::Operations::HrisListEmployeeTimeOffBalancesResponse.new( status_code: http_response.status, content_type: content_type, raw_response: http_response, - tasks_paginated: obj + time_off_balances_paginated: obj ) return response @@ -13353,19 +13905,19 @@ def list_employee_tasks(request, retries = nil, timeout_ms = nil) end - sig { params(request: T.nilable(Models::Operations::HrisListEmployeeTimeOffBalancesRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::HrisListEmployeeTimeOffBalancesResponse) } - def list_employee_time_off_balances(request, retries = nil, timeout_ms = nil) - # list_employee_time_off_balances - List Employee Time Off Balances + sig { params(request: T.nilable(Models::Operations::HrisListEmployeeTimeOffPoliciesRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::HrisListEmployeeTimeOffPoliciesResponse) } + def list_employee_time_off_policies(request, retries = nil, timeout_ms = nil) + # list_employee_time_off_policies - List Assigned Time Off Policies url, params = @sdk_configuration.get_server_details base_url = Utils.template_url(url, params) url = Utils.generate_url( - Models::Operations::HrisListEmployeeTimeOffBalancesRequest, + Models::Operations::HrisListEmployeeTimeOffPoliciesRequest, base_url, - '/unified/hris/employees/{id}/time_off_balances', + '/unified/hris/employees/{id}/time_off_policies', request ) headers = Utils.get_headers(request) - query_params = Utils.get_query_params(Models::Operations::HrisListEmployeeTimeOffBalancesRequest, request) + query_params = Utils.get_query_params(Models::Operations::HrisListEmployeeTimeOffPoliciesRequest, request) headers['Accept'] = 'application/json' headers['user-agent'] = @sdk_configuration.user_agent retries ||= @sdk_configuration.retry_config @@ -13393,7 +13945,7 @@ def list_employee_time_off_balances(request, retries = nil, timeout_ms = nil) hook_ctx = SDKHooks::HookContext.new( base_url: base_url, oauth2_scopes: [], - operation_id: 'hris_list_employee_time_off_balances', + operation_id: 'hris_list_employee_time_off_policies', security_source: @sdk_configuration.security_source ) @@ -13450,12 +14002,12 @@ def list_employee_time_off_balances(request, retries = nil, timeout_ms = nil) ), response: http_response ) - obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::TimeOffBalancesPaginated) - response = Models::Operations::HrisListEmployeeTimeOffBalancesResponse.new( + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::TimeOffPoliciesPaginated) + response = Models::Operations::HrisListEmployeeTimeOffPoliciesResponse.new( status_code: http_response.status, content_type: content_type, raw_response: http_response, - time_off_balances_paginated: obj + time_off_policies_paginated: obj ) return response @@ -13629,19 +14181,19 @@ def list_employee_time_off_balances(request, retries = nil, timeout_ms = nil) end - sig { params(request: T.nilable(Models::Operations::HrisListEmployeeTimeOffPoliciesRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::HrisListEmployeeTimeOffPoliciesResponse) } - def list_employee_time_off_policies(request, retries = nil, timeout_ms = nil) - # list_employee_time_off_policies - List Assigned Time Off Policies + sig { params(request: T.nilable(Models::Operations::HrisListEmployeeTimeOffRequestsRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::HrisListEmployeeTimeOffRequestsResponse) } + def list_employee_time_off_requests(request, retries = nil, timeout_ms = nil) + # list_employee_time_off_requests - List Employee Time Off Requests url, params = @sdk_configuration.get_server_details base_url = Utils.template_url(url, params) url = Utils.generate_url( - Models::Operations::HrisListEmployeeTimeOffPoliciesRequest, + Models::Operations::HrisListEmployeeTimeOffRequestsRequest, base_url, - '/unified/hris/employees/{id}/time_off_policies', + '/unified/hris/employees/{id}/time_off', request ) headers = Utils.get_headers(request) - query_params = Utils.get_query_params(Models::Operations::HrisListEmployeeTimeOffPoliciesRequest, request) + query_params = Utils.get_query_params(Models::Operations::HrisListEmployeeTimeOffRequestsRequest, request) headers['Accept'] = 'application/json' headers['user-agent'] = @sdk_configuration.user_agent retries ||= @sdk_configuration.retry_config @@ -13669,7 +14221,7 @@ def list_employee_time_off_policies(request, retries = nil, timeout_ms = nil) hook_ctx = SDKHooks::HookContext.new( base_url: base_url, oauth2_scopes: [], - operation_id: 'hris_list_employee_time_off_policies', + operation_id: 'hris_list_employee_time_off_requests', security_source: @sdk_configuration.security_source ) @@ -13726,12 +14278,12 @@ def list_employee_time_off_policies(request, retries = nil, timeout_ms = nil) ), response: http_response ) - obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::TimeOffPoliciesPaginated) - response = Models::Operations::HrisListEmployeeTimeOffPoliciesResponse.new( + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::TimeOffPaginated) + response = Models::Operations::HrisListEmployeeTimeOffRequestsResponse.new( status_code: http_response.status, content_type: content_type, raw_response: http_response, - time_off_policies_paginated: obj + time_off_paginated: obj ) return response @@ -13905,19 +14457,19 @@ def list_employee_time_off_policies(request, retries = nil, timeout_ms = nil) end - sig { params(request: T.nilable(Models::Operations::HrisListEmployeeTimeOffRequestsRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::HrisListEmployeeTimeOffRequestsResponse) } - def list_employee_time_off_requests(request, retries = nil, timeout_ms = nil) - # list_employee_time_off_requests - List Employee Time Off Requests + sig { params(request: T.nilable(Models::Operations::HrisListEmployeeWorkEligibilityRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::HrisListEmployeeWorkEligibilityResponse) } + def list_employee_work_eligibility(request, retries = nil, timeout_ms = nil) + # list_employee_work_eligibility - List Employee Work Eligibility url, params = @sdk_configuration.get_server_details base_url = Utils.template_url(url, params) url = Utils.generate_url( - Models::Operations::HrisListEmployeeTimeOffRequestsRequest, + Models::Operations::HrisListEmployeeWorkEligibilityRequest, base_url, - '/unified/hris/employees/{id}/time_off', + '/unified/hris/employees/{id}/work_eligibility', request ) headers = Utils.get_headers(request) - query_params = Utils.get_query_params(Models::Operations::HrisListEmployeeTimeOffRequestsRequest, request) + query_params = Utils.get_query_params(Models::Operations::HrisListEmployeeWorkEligibilityRequest, request) headers['Accept'] = 'application/json' headers['user-agent'] = @sdk_configuration.user_agent retries ||= @sdk_configuration.retry_config @@ -13945,7 +14497,7 @@ def list_employee_time_off_requests(request, retries = nil, timeout_ms = nil) hook_ctx = SDKHooks::HookContext.new( base_url: base_url, oauth2_scopes: [], - operation_id: 'hris_list_employee_time_off_requests', + operation_id: 'hris_list_employee_work_eligibility', security_source: @sdk_configuration.security_source ) @@ -14002,12 +14554,12 @@ def list_employee_time_off_requests(request, retries = nil, timeout_ms = nil) ), response: http_response ) - obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::TimeOffPaginated) - response = Models::Operations::HrisListEmployeeTimeOffRequestsResponse.new( + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::WorkEligibilityPaginated) + response = Models::Operations::HrisListEmployeeWorkEligibilityResponse.new( status_code: http_response.status, content_type: content_type, raw_response: http_response, - time_off_paginated: obj + work_eligibility_paginated: obj ) return response @@ -14181,19 +14733,14 @@ def list_employee_time_off_requests(request, retries = nil, timeout_ms = nil) end - sig { params(request: T.nilable(Models::Operations::HrisListEmployeeWorkEligibilityRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::HrisListEmployeeWorkEligibilityResponse) } - def list_employee_work_eligibility(request, retries = nil, timeout_ms = nil) - # list_employee_work_eligibility - List Employee Work Eligibility + sig { params(request: T.nilable(Models::Operations::HrisListEmployeesRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::HrisListEmployeesResponse) } + def list_employees(request, retries = nil, timeout_ms = nil) + # list_employees - List Employees url, params = @sdk_configuration.get_server_details base_url = Utils.template_url(url, params) - url = Utils.generate_url( - Models::Operations::HrisListEmployeeWorkEligibilityRequest, - base_url, - '/unified/hris/employees/{id}/work_eligibility', - request - ) + url = "#{base_url}/unified/hris/employees" headers = Utils.get_headers(request) - query_params = Utils.get_query_params(Models::Operations::HrisListEmployeeWorkEligibilityRequest, request) + query_params = Utils.get_query_params(Models::Operations::HrisListEmployeesRequest, request) headers['Accept'] = 'application/json' headers['user-agent'] = @sdk_configuration.user_agent retries ||= @sdk_configuration.retry_config @@ -14221,7 +14768,7 @@ def list_employee_work_eligibility(request, retries = nil, timeout_ms = nil) hook_ctx = SDKHooks::HookContext.new( base_url: base_url, oauth2_scopes: [], - operation_id: 'hris_list_employee_work_eligibility', + operation_id: 'hris_list_employees', security_source: @sdk_configuration.security_source ) @@ -14278,12 +14825,12 @@ def list_employee_work_eligibility(request, retries = nil, timeout_ms = nil) ), response: http_response ) - obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::WorkEligibilityPaginated) - response = Models::Operations::HrisListEmployeeWorkEligibilityResponse.new( + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::EmployeesPaginated) + response = Models::Operations::HrisListEmployeesResponse.new( status_code: http_response.status, content_type: content_type, raw_response: http_response, - work_eligibility_paginated: obj + employees_paginated: obj ) return response @@ -14457,14 +15004,14 @@ def list_employee_work_eligibility(request, retries = nil, timeout_ms = nil) end - sig { params(request: T.nilable(Models::Operations::HrisListEmployeesRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::HrisListEmployeesResponse) } - def list_employees(request, retries = nil, timeout_ms = nil) - # list_employees - List Employees + sig { params(request: T.nilable(Models::Operations::HrisListEmploymentsRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::HrisListEmploymentsResponse) } + def list_employments(request, retries = nil, timeout_ms = nil) + # list_employments - List Employments url, params = @sdk_configuration.get_server_details base_url = Utils.template_url(url, params) - url = "#{base_url}/unified/hris/employees" + url = "#{base_url}/unified/hris/employments" headers = Utils.get_headers(request) - query_params = Utils.get_query_params(Models::Operations::HrisListEmployeesRequest, request) + query_params = Utils.get_query_params(Models::Operations::HrisListEmploymentsRequest, request) headers['Accept'] = 'application/json' headers['user-agent'] = @sdk_configuration.user_agent retries ||= @sdk_configuration.retry_config @@ -14492,7 +15039,7 @@ def list_employees(request, retries = nil, timeout_ms = nil) hook_ctx = SDKHooks::HookContext.new( base_url: base_url, oauth2_scopes: [], - operation_id: 'hris_list_employees', + operation_id: 'hris_list_employments', security_source: @sdk_configuration.security_source ) @@ -14549,12 +15096,12 @@ def list_employees(request, retries = nil, timeout_ms = nil) ), response: http_response ) - obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::EmployeesPaginated) - response = Models::Operations::HrisListEmployeesResponse.new( + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::EmploymentsPaginated) + response = Models::Operations::HrisListEmploymentsResponse.new( status_code: http_response.status, content_type: content_type, raw_response: http_response, - employees_paginated: obj + employments_paginated: obj ) return response @@ -14728,14 +15275,14 @@ def list_employees(request, retries = nil, timeout_ms = nil) end - sig { params(request: T.nilable(Models::Operations::HrisListEmploymentsRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::HrisListEmploymentsResponse) } - def list_employments(request, retries = nil, timeout_ms = nil) - # list_employments - List Employments + sig { params(request: T.nilable(Models::Operations::HrisListGroupsRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::HrisListGroupsResponse) } + def list_groups(request, retries = nil, timeout_ms = nil) + # list_groups - List Groups url, params = @sdk_configuration.get_server_details base_url = Utils.template_url(url, params) - url = "#{base_url}/unified/hris/employments" + url = "#{base_url}/unified/hris/groups" headers = Utils.get_headers(request) - query_params = Utils.get_query_params(Models::Operations::HrisListEmploymentsRequest, request) + query_params = Utils.get_query_params(Models::Operations::HrisListGroupsRequest, request) headers['Accept'] = 'application/json' headers['user-agent'] = @sdk_configuration.user_agent retries ||= @sdk_configuration.retry_config @@ -14763,7 +15310,7 @@ def list_employments(request, retries = nil, timeout_ms = nil) hook_ctx = SDKHooks::HookContext.new( base_url: base_url, oauth2_scopes: [], - operation_id: 'hris_list_employments', + operation_id: 'hris_list_groups', security_source: @sdk_configuration.security_source ) @@ -14820,12 +15367,12 @@ def list_employments(request, retries = nil, timeout_ms = nil) ), response: http_response ) - obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::EmploymentsPaginated) - response = Models::Operations::HrisListEmploymentsResponse.new( + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::HRISGroupsPaginated) + response = Models::Operations::HrisListGroupsResponse.new( status_code: http_response.status, content_type: content_type, raw_response: http_response, - employments_paginated: obj + hris_groups_paginated: obj ) return response @@ -14999,14 +15546,14 @@ def list_employments(request, retries = nil, timeout_ms = nil) end - sig { params(request: T.nilable(Models::Operations::HrisListGroupsRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::HrisListGroupsResponse) } - def list_groups(request, retries = nil, timeout_ms = nil) - # list_groups - List Groups + sig { params(request: T.nilable(Models::Operations::HrisListJobsRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::HrisListJobsResponse) } + def list_jobs(request, retries = nil, timeout_ms = nil) + # list_jobs - List Jobs url, params = @sdk_configuration.get_server_details base_url = Utils.template_url(url, params) - url = "#{base_url}/unified/hris/groups" + url = "#{base_url}/unified/hris/jobs" headers = Utils.get_headers(request) - query_params = Utils.get_query_params(Models::Operations::HrisListGroupsRequest, request) + query_params = Utils.get_query_params(Models::Operations::HrisListJobsRequest, request) headers['Accept'] = 'application/json' headers['user-agent'] = @sdk_configuration.user_agent retries ||= @sdk_configuration.retry_config @@ -15034,7 +15581,7 @@ def list_groups(request, retries = nil, timeout_ms = nil) hook_ctx = SDKHooks::HookContext.new( base_url: base_url, oauth2_scopes: [], - operation_id: 'hris_list_groups', + operation_id: 'hris_list_jobs', security_source: @sdk_configuration.security_source ) @@ -15091,12 +15638,12 @@ def list_groups(request, retries = nil, timeout_ms = nil) ), response: http_response ) - obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::HRISGroupsPaginated) - response = Models::Operations::HrisListGroupsResponse.new( + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::JobsPaginated) + response = Models::Operations::HrisListJobsResponse.new( status_code: http_response.status, content_type: content_type, raw_response: http_response, - hris_groups_paginated: obj + jobs_paginated: obj ) return response @@ -15270,14 +15817,14 @@ def list_groups(request, retries = nil, timeout_ms = nil) end - sig { params(request: T.nilable(Models::Operations::HrisListJobsRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::HrisListJobsResponse) } - def list_jobs(request, retries = nil, timeout_ms = nil) - # list_jobs - List Jobs + sig { params(request: T.nilable(Models::Operations::HrisListLocationsRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::HrisListLocationsResponse) } + def list_locations(request, retries = nil, timeout_ms = nil) + # list_locations - List Work Locations url, params = @sdk_configuration.get_server_details base_url = Utils.template_url(url, params) - url = "#{base_url}/unified/hris/jobs" + url = "#{base_url}/unified/hris/locations" headers = Utils.get_headers(request) - query_params = Utils.get_query_params(Models::Operations::HrisListJobsRequest, request) + query_params = Utils.get_query_params(Models::Operations::HrisListLocationsRequest, request) headers['Accept'] = 'application/json' headers['user-agent'] = @sdk_configuration.user_agent retries ||= @sdk_configuration.retry_config @@ -15305,7 +15852,7 @@ def list_jobs(request, retries = nil, timeout_ms = nil) hook_ctx = SDKHooks::HookContext.new( base_url: base_url, oauth2_scopes: [], - operation_id: 'hris_list_jobs', + operation_id: 'hris_list_locations', security_source: @sdk_configuration.security_source ) @@ -15362,12 +15909,12 @@ def list_jobs(request, retries = nil, timeout_ms = nil) ), response: http_response ) - obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::JobsPaginated) - response = Models::Operations::HrisListJobsResponse.new( + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::HRISLocationsPaginated) + response = Models::Operations::HrisListLocationsResponse.new( status_code: http_response.status, content_type: content_type, raw_response: http_response, - jobs_paginated: obj + hris_locations_paginated: obj ) return response @@ -15541,14 +16088,14 @@ def list_jobs(request, retries = nil, timeout_ms = nil) end - sig { params(request: T.nilable(Models::Operations::HrisListLocationsRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::HrisListLocationsResponse) } - def list_locations(request, retries = nil, timeout_ms = nil) - # list_locations - List Work Locations + sig { params(request: T.nilable(Models::Operations::HrisListPositionsRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::HrisListPositionsResponse) } + def list_positions(request, retries = nil, timeout_ms = nil) + # list_positions - List Positions url, params = @sdk_configuration.get_server_details base_url = Utils.template_url(url, params) - url = "#{base_url}/unified/hris/locations" + url = "#{base_url}/unified/hris/positions" headers = Utils.get_headers(request) - query_params = Utils.get_query_params(Models::Operations::HrisListLocationsRequest, request) + query_params = Utils.get_query_params(Models::Operations::HrisListPositionsRequest, request) headers['Accept'] = 'application/json' headers['user-agent'] = @sdk_configuration.user_agent retries ||= @sdk_configuration.retry_config @@ -15576,7 +16123,7 @@ def list_locations(request, retries = nil, timeout_ms = nil) hook_ctx = SDKHooks::HookContext.new( base_url: base_url, oauth2_scopes: [], - operation_id: 'hris_list_locations', + operation_id: 'hris_list_positions', security_source: @sdk_configuration.security_source ) @@ -15633,12 +16180,12 @@ def list_locations(request, retries = nil, timeout_ms = nil) ), response: http_response ) - obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::HRISLocationsPaginated) - response = Models::Operations::HrisListLocationsResponse.new( + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::PositionsPaginated) + response = Models::Operations::HrisListPositionsResponse.new( status_code: http_response.status, content_type: content_type, raw_response: http_response, - hris_locations_paginated: obj + positions_paginated: obj ) return response @@ -15812,14 +16359,14 @@ def list_locations(request, retries = nil, timeout_ms = nil) end - sig { params(request: T.nilable(Models::Operations::HrisListPositionsRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::HrisListPositionsResponse) } - def list_positions(request, retries = nil, timeout_ms = nil) - # list_positions - List Positions + sig { params(request: T.nilable(Models::Operations::HrisListShiftsRequest), retries: T.nilable(Utils::RetryConfig), timeout_ms: T.nilable(Integer)).returns(Models::Operations::HrisListShiftsResponse) } + def list_shifts(request, retries = nil, timeout_ms = nil) + # list_shifts - List Shifts url, params = @sdk_configuration.get_server_details base_url = Utils.template_url(url, params) - url = "#{base_url}/unified/hris/positions" + url = "#{base_url}/unified/hris/shifts" headers = Utils.get_headers(request) - query_params = Utils.get_query_params(Models::Operations::HrisListPositionsRequest, request) + query_params = Utils.get_query_params(Models::Operations::HrisListShiftsRequest, request) headers['Accept'] = 'application/json' headers['user-agent'] = @sdk_configuration.user_agent retries ||= @sdk_configuration.retry_config @@ -15847,7 +16394,7 @@ def list_positions(request, retries = nil, timeout_ms = nil) hook_ctx = SDKHooks::HookContext.new( base_url: base_url, oauth2_scopes: [], - operation_id: 'hris_list_positions', + operation_id: 'hris_list_shifts', security_source: @sdk_configuration.security_source ) @@ -15904,12 +16451,12 @@ def list_positions(request, retries = nil, timeout_ms = nil) ), response: http_response ) - obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::PositionsPaginated) - response = Models::Operations::HrisListPositionsResponse.new( + obj = Crystalline.unmarshal_json(JSON.parse(http_response.env.response_body), Models::Shared::HrisShiftsPaginated) + response = Models::Operations::HrisListShiftsResponse.new( status_code: http_response.status, content_type: content_type, raw_response: http_response, - positions_paginated: obj + hris_shifts_paginated: obj ) return response diff --git a/lib/stack_one/models/operations.rb b/lib/stack_one/models/operations.rb index c7e06ed4..9c0a3b34 100644 --- a/lib/stack_one/models/operations.rb +++ b/lib/stack_one/models/operations.rb @@ -27,6 +27,8 @@ module Operations autoload :AtsGetApplicationCustomFieldDefinitionQueryParamFilter, 'stack_one/models/operations/ats_get_application_custom_field_definition_queryparam_filter.rb' autoload :AtsGetApplicationCustomFieldDefinitionRequest, 'stack_one/models/operations/ats_get_application_custom_field_definition_request.rb' autoload :AtsGetApplicationCustomFieldDefinitionResponse, 'stack_one/models/operations/ats_get_application_custom_field_definition_response.rb' + autoload :AtsGetApplicationDocumentCategoryRequest, 'stack_one/models/operations/ats_get_application_document_category_request.rb' + autoload :AtsGetApplicationDocumentCategoryResponse, 'stack_one/models/operations/ats_get_application_document_category_response.rb' autoload :AtsGetApplicationDocumentRequest, 'stack_one/models/operations/ats_get_application_document_request.rb' autoload :AtsGetApplicationDocumentResponse, 'stack_one/models/operations/ats_get_application_document_response.rb' autoload :AtsGetApplicationNoteRequest, 'stack_one/models/operations/ats_get_application_note_request.rb' @@ -83,6 +85,9 @@ module Operations autoload :AtsListApplicationCustomFieldDefinitionsQueryParamFilter, 'stack_one/models/operations/ats_list_application_custom_field_definitions_queryparam_filter.rb' autoload :AtsListApplicationCustomFieldDefinitionsRequest, 'stack_one/models/operations/ats_list_application_custom_field_definitions_request.rb' autoload :AtsListApplicationCustomFieldDefinitionsResponse, 'stack_one/models/operations/ats_list_application_custom_field_definitions_response.rb' + autoload :AtsListApplicationDocumentCategoriesQueryParamFilter, 'stack_one/models/operations/ats_list_application_document_categories_queryparam_filter.rb' + autoload :AtsListApplicationDocumentCategoriesRequest, 'stack_one/models/operations/ats_list_application_document_categories_request.rb' + autoload :AtsListApplicationDocumentCategoriesResponse, 'stack_one/models/operations/ats_list_application_document_categories_response.rb' autoload :AtsListApplicationDocumentsQueryParamFilter, 'stack_one/models/operations/ats_list_application_documents_queryparam_filter.rb' autoload :AtsListApplicationDocumentsRequest, 'stack_one/models/operations/ats_list_application_documents_request.rb' autoload :AtsListApplicationDocumentsResponse, 'stack_one/models/operations/ats_list_application_documents_response.rb' @@ -259,6 +264,8 @@ module Operations autoload :HrisGetLocationResponse, 'stack_one/models/operations/hris_get_location_response.rb' autoload :HrisGetPositionRequest, 'stack_one/models/operations/hris_get_position_request.rb' autoload :HrisGetPositionResponse, 'stack_one/models/operations/hris_get_position_response.rb' + autoload :HrisGetShiftRequest, 'stack_one/models/operations/hris_get_shift_request.rb' + autoload :HrisGetShiftResponse, 'stack_one/models/operations/hris_get_shift_response.rb' autoload :HrisGetTaskRequest, 'stack_one/models/operations/hris_get_task_request.rb' autoload :HrisGetTaskResponse, 'stack_one/models/operations/hris_get_task_response.rb' autoload :HrisGetTeamGroupRequest, 'stack_one/models/operations/hris_get_team_group_request.rb' @@ -339,6 +346,10 @@ module Operations autoload :HrisListPositionsQueryParamFilter, 'stack_one/models/operations/hris_list_positions_queryparam_filter.rb' autoload :HrisListPositionsRequest, 'stack_one/models/operations/hris_list_positions_request.rb' autoload :HrisListPositionsResponse, 'stack_one/models/operations/hris_list_positions_response.rb' + autoload :HrisListShiftsQueryParamFilter, 'stack_one/models/operations/hris_list_shifts_queryparam_filter.rb' + autoload :HrisListShiftsQueryParamStatus, 'stack_one/models/operations/hris_list_shifts_queryparam_status.rb' + autoload :HrisListShiftsRequest, 'stack_one/models/operations/hris_list_shifts_request.rb' + autoload :HrisListShiftsResponse, 'stack_one/models/operations/hris_list_shifts_response.rb' autoload :HrisListTasksQueryParamFilter, 'stack_one/models/operations/hris_list_tasks_queryparam_filter.rb' autoload :HrisListTasksRequest, 'stack_one/models/operations/hris_list_tasks_request.rb' autoload :HrisListTasksResponse, 'stack_one/models/operations/hris_list_tasks_response.rb' diff --git a/lib/stack_one/models/operations/ats_get_application_document_category_request.rb b/lib/stack_one/models/operations/ats_get_application_document_category_request.rb new file mode 100644 index 00000000..451f05b7 --- /dev/null +++ b/lib/stack_one/models/operations/ats_get_application_document_category_request.rb @@ -0,0 +1,49 @@ +# Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +# typed: true +# frozen_string_literal: true + + +module StackOne + module Models + module Operations + + + class AtsGetApplicationDocumentCategoryRequest + extend T::Sig + include Crystalline::MetadataFields + + + field :id, ::String, { 'path_param': { 'field_name': 'id', 'style': 'simple', 'explode': false } } + # The account identifier + field :x_account_id, ::String, { 'header': { 'field_name': 'x-account-id', 'style': 'simple', 'explode': false } } + # The comma separated list of fields that will be returned in the response (if empty, all fields are returned) + field :fields_, T.nilable(::String), { 'query_param': { 'field_name': 'fields', 'style': 'form', 'explode': true } } + # Query parameters that can be used to pass through parameters to the underlying provider request by surrounding them with 'proxy' key + field :proxy, T.nilable(T::Hash[Symbol, ::Object]), { 'query_param': { 'field_name': 'proxy', 'style': 'deepObject', 'explode': true } } + # Indicates that the raw request result should be returned in addition to the mapped result (default value is false) + field :raw, T.nilable(T::Boolean), { 'query_param': { 'field_name': 'raw', 'style': 'form', 'explode': true } } + + + sig { params(id: ::String, x_account_id: ::String, fields_: T.nilable(::String), proxy: T.nilable(T::Hash[Symbol, ::Object]), raw: T.nilable(T::Boolean)).void } + def initialize(id: nil, x_account_id: nil, fields_: nil, proxy: nil, raw: nil) + @id = id + @x_account_id = x_account_id + @fields_ = fields_ + @proxy = proxy + @raw = raw + end + + def ==(other) + return false unless other.is_a? self.class + return false unless @id == other.id + return false unless @x_account_id == other.x_account_id + return false unless @fields_ == other.fields_ + return false unless @proxy == other.proxy + return false unless @raw == other.raw + true + end + end + end + end +end diff --git a/lib/stack_one/models/operations/ats_get_application_document_category_response.rb b/lib/stack_one/models/operations/ats_get_application_document_category_response.rb new file mode 100644 index 00000000..3cd24876 --- /dev/null +++ b/lib/stack_one/models/operations/ats_get_application_document_category_response.rb @@ -0,0 +1,49 @@ +# Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +# typed: true +# frozen_string_literal: true + + +module StackOne + module Models + module Operations + + + class AtsGetApplicationDocumentCategoryResponse + extend T::Sig + include Crystalline::MetadataFields + + # HTTP response content type for this operation + field :content_type, ::String + + field :headers, T::Hash[Symbol, T::Array[::String]] + # Raw HTTP response; suitable for custom response parsing + field :raw_response, ::Faraday::Response + # HTTP response status code for this operation + field :status_code, ::Integer + # The application document category with the given identifier was retrieved. + field :reference_result, T.nilable(Models::Shared::ReferenceResult) + + + sig { params(content_type: ::String, headers: T::Hash[Symbol, T::Array[::String]], raw_response: ::Faraday::Response, status_code: ::Integer, reference_result: T.nilable(Models::Shared::ReferenceResult)).void } + def initialize(content_type: nil, headers: nil, raw_response: nil, status_code: nil, reference_result: nil) + @content_type = content_type + @headers = headers + @raw_response = raw_response + @status_code = status_code + @reference_result = reference_result + end + + def ==(other) + return false unless other.is_a? self.class + return false unless @content_type == other.content_type + return false unless @headers == other.headers + return false unless @raw_response == other.raw_response + return false unless @status_code == other.status_code + return false unless @reference_result == other.reference_result + true + end + end + end + end +end diff --git a/lib/stack_one/models/operations/ats_list_application_document_categories_queryparam_filter.rb b/lib/stack_one/models/operations/ats_list_application_document_categories_queryparam_filter.rb new file mode 100644 index 00000000..2d9d1065 --- /dev/null +++ b/lib/stack_one/models/operations/ats_list_application_document_categories_queryparam_filter.rb @@ -0,0 +1,33 @@ +# Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +# typed: true +# frozen_string_literal: true + + +module StackOne + module Models + module Operations + + # Filter parameters that allow greater customisation of the list response + class AtsListApplicationDocumentCategoriesQueryParamFilter + extend T::Sig + include Crystalline::MetadataFields + + # Use a string with a date to only select results updated after that given date + field :updated_after, T.nilable(::String), { 'query_param': { 'field_name': 'updated_after' } } + + + sig { params(updated_after: T.nilable(::String)).void } + def initialize(updated_after: nil) + @updated_after = updated_after + end + + def ==(other) + return false unless other.is_a? self.class + return false unless @updated_after == other.updated_after + true + end + end + end + end +end diff --git a/lib/stack_one/models/operations/ats_list_application_document_categories_request.rb b/lib/stack_one/models/operations/ats_list_application_document_categories_request.rb new file mode 100644 index 00000000..ebe1bcaa --- /dev/null +++ b/lib/stack_one/models/operations/ats_list_application_document_categories_request.rb @@ -0,0 +1,69 @@ +# Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +# typed: true +# frozen_string_literal: true + + +module StackOne + module Models + module Operations + + + class AtsListApplicationDocumentCategoriesRequest + extend T::Sig + include Crystalline::MetadataFields + + # The account identifier + field :x_account_id, ::String, { 'header': { 'field_name': 'x-account-id', 'style': 'simple', 'explode': false } } + # The comma separated list of fields that will be returned in the response (if empty, all fields are returned) + field :fields_, T.nilable(::String), { 'query_param': { 'field_name': 'fields', 'style': 'form', 'explode': true } } + # Filter parameters that allow greater customisation of the list response + field :filter, T.nilable(Models::Operations::AtsListApplicationDocumentCategoriesQueryParamFilter), { 'query_param': { 'field_name': 'filter', 'style': 'deepObject', 'explode': true } } + # The unified cursor + field :next_, T.nilable(::String), { 'query_param': { 'field_name': 'next', 'style': 'form', 'explode': true } } + # The page number of the results to fetch + # + # @deprecated true: This will be removed in a future release, please migrate away from it as soon as possible. + field :page, T.nilable(::String), { 'query_param': { 'field_name': 'page', 'style': 'form', 'explode': true } } + # The number of results per page (default value is 25) + field :page_size, T.nilable(::String), { 'query_param': { 'field_name': 'page_size', 'style': 'form', 'explode': true } } + # Query parameters that can be used to pass through parameters to the underlying provider request by surrounding them with 'proxy' key + field :proxy, T.nilable(T::Hash[Symbol, ::Object]), { 'query_param': { 'field_name': 'proxy', 'style': 'deepObject', 'explode': true } } + # Indicates that the raw request result should be returned in addition to the mapped result (default value is false) + field :raw, T.nilable(T::Boolean), { 'query_param': { 'field_name': 'raw', 'style': 'form', 'explode': true } } + # Use a string with a date to only select results updated after that given date + # + # @deprecated true: This will be removed in a future release, please migrate away from it as soon as possible. + field :updated_after, T.nilable(::String), { 'query_param': { 'field_name': 'updated_after', 'style': 'form', 'explode': true } } + + + sig { params(x_account_id: ::String, fields_: T.nilable(::String), filter: T.nilable(Models::Operations::AtsListApplicationDocumentCategoriesQueryParamFilter), next_: T.nilable(::String), page: T.nilable(::String), page_size: T.nilable(::String), proxy: T.nilable(T::Hash[Symbol, ::Object]), raw: T.nilable(T::Boolean), updated_after: T.nilable(::String)).void } + def initialize(x_account_id: nil, fields_: nil, filter: nil, next_: nil, page: nil, page_size: nil, proxy: nil, raw: nil, updated_after: nil) + @x_account_id = x_account_id + @fields_ = fields_ + @filter = filter + @next_ = next_ + @page = page + @page_size = page_size + @proxy = proxy + @raw = raw + @updated_after = updated_after + end + + def ==(other) + return false unless other.is_a? self.class + return false unless @x_account_id == other.x_account_id + return false unless @fields_ == other.fields_ + return false unless @filter == other.filter + return false unless @next_ == other.next_ + return false unless @page == other.page + return false unless @page_size == other.page_size + return false unless @proxy == other.proxy + return false unless @raw == other.raw + return false unless @updated_after == other.updated_after + true + end + end + end + end +end diff --git a/lib/stack_one/models/operations/ats_list_application_document_categories_response.rb b/lib/stack_one/models/operations/ats_list_application_document_categories_response.rb new file mode 100644 index 00000000..c67514cf --- /dev/null +++ b/lib/stack_one/models/operations/ats_list_application_document_categories_response.rb @@ -0,0 +1,49 @@ +# Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +# typed: true +# frozen_string_literal: true + + +module StackOne + module Models + module Operations + + + class AtsListApplicationDocumentCategoriesResponse + extend T::Sig + include Crystalline::MetadataFields + + # HTTP response content type for this operation + field :content_type, ::String + + field :headers, T::Hash[Symbol, T::Array[::String]] + # Raw HTTP response; suitable for custom response parsing + field :raw_response, ::Faraday::Response + # HTTP response status code for this operation + field :status_code, ::Integer + # The list of application document categories were retrieved. + field :reference_paginated, T.nilable(Models::Shared::ReferencePaginated) + + + sig { params(content_type: ::String, headers: T::Hash[Symbol, T::Array[::String]], raw_response: ::Faraday::Response, status_code: ::Integer, reference_paginated: T.nilable(Models::Shared::ReferencePaginated)).void } + def initialize(content_type: nil, headers: nil, raw_response: nil, status_code: nil, reference_paginated: nil) + @content_type = content_type + @headers = headers + @raw_response = raw_response + @status_code = status_code + @reference_paginated = reference_paginated + end + + def ==(other) + return false unless other.is_a? self.class + return false unless @content_type == other.content_type + return false unless @headers == other.headers + return false unless @raw_response == other.raw_response + return false unless @status_code == other.status_code + return false unless @reference_paginated == other.reference_paginated + true + end + end + end + end +end diff --git a/lib/stack_one/models/operations/hris_get_shift_request.rb b/lib/stack_one/models/operations/hris_get_shift_request.rb new file mode 100644 index 00000000..d36b9c90 --- /dev/null +++ b/lib/stack_one/models/operations/hris_get_shift_request.rb @@ -0,0 +1,49 @@ +# Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +# typed: true +# frozen_string_literal: true + + +module StackOne + module Models + module Operations + + + class HrisGetShiftRequest + extend T::Sig + include Crystalline::MetadataFields + + + field :id, ::String, { 'path_param': { 'field_name': 'id', 'style': 'simple', 'explode': false } } + # The account identifier + field :x_account_id, ::String, { 'header': { 'field_name': 'x-account-id', 'style': 'simple', 'explode': false } } + # The comma separated list of fields to return in the response (if empty, all fields are returned) + field :fields_, T.nilable(::String), { 'query_param': { 'field_name': 'fields', 'style': 'form', 'explode': true } } + # Query parameters that can be used to pass through parameters to the underlying provider request by surrounding them with 'proxy' key + field :proxy, T.nilable(T::Hash[Symbol, ::Object]), { 'query_param': { 'field_name': 'proxy', 'style': 'deepObject', 'explode': true } } + # Indicates that the raw request result should be returned in addition to the mapped result (default value is false) + field :raw, T.nilable(T::Boolean), { 'query_param': { 'field_name': 'raw', 'style': 'form', 'explode': true } } + + + sig { params(id: ::String, x_account_id: ::String, fields_: T.nilable(::String), proxy: T.nilable(T::Hash[Symbol, ::Object]), raw: T.nilable(T::Boolean)).void } + def initialize(id: nil, x_account_id: nil, fields_: nil, proxy: nil, raw: nil) + @id = id + @x_account_id = x_account_id + @fields_ = fields_ + @proxy = proxy + @raw = raw + end + + def ==(other) + return false unless other.is_a? self.class + return false unless @id == other.id + return false unless @x_account_id == other.x_account_id + return false unless @fields_ == other.fields_ + return false unless @proxy == other.proxy + return false unless @raw == other.raw + true + end + end + end + end +end diff --git a/lib/stack_one/models/operations/hris_get_shift_response.rb b/lib/stack_one/models/operations/hris_get_shift_response.rb new file mode 100644 index 00000000..4777daa1 --- /dev/null +++ b/lib/stack_one/models/operations/hris_get_shift_response.rb @@ -0,0 +1,49 @@ +# Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +# typed: true +# frozen_string_literal: true + + +module StackOne + module Models + module Operations + + + class HrisGetShiftResponse + extend T::Sig + include Crystalline::MetadataFields + + # HTTP response content type for this operation + field :content_type, ::String + + field :headers, T::Hash[Symbol, T::Array[::String]] + # Raw HTTP response; suitable for custom response parsing + field :raw_response, ::Faraday::Response + # HTTP response status code for this operation + field :status_code, ::Integer + # The shift with the given identifier was retrieved. + field :hris_shift_result, T.nilable(Models::Shared::HrisShiftResult) + + + sig { params(content_type: ::String, headers: T::Hash[Symbol, T::Array[::String]], raw_response: ::Faraday::Response, status_code: ::Integer, hris_shift_result: T.nilable(Models::Shared::HrisShiftResult)).void } + def initialize(content_type: nil, headers: nil, raw_response: nil, status_code: nil, hris_shift_result: nil) + @content_type = content_type + @headers = headers + @raw_response = raw_response + @status_code = status_code + @hris_shift_result = hris_shift_result + end + + def ==(other) + return false unless other.is_a? self.class + return false unless @content_type == other.content_type + return false unless @headers == other.headers + return false unless @raw_response == other.raw_response + return false unless @status_code == other.status_code + return false unless @hris_shift_result == other.hris_shift_result + true + end + end + end + end +end diff --git a/lib/stack_one/models/operations/hris_list_shifts_queryparam_filter.rb b/lib/stack_one/models/operations/hris_list_shifts_queryparam_filter.rb new file mode 100644 index 00000000..36856f95 --- /dev/null +++ b/lib/stack_one/models/operations/hris_list_shifts_queryparam_filter.rb @@ -0,0 +1,49 @@ +# Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +# typed: true +# frozen_string_literal: true + + +module StackOne + module Models + module Operations + + # HRIS Shifts filters + class HrisListShiftsQueryParamFilter + extend T::Sig + include Crystalline::MetadataFields + + # Filter to select shifts by employee ID + field :employee_id, T.nilable(::String), { 'query_param': { 'field_name': 'employee_id' } } + # Filter shifts that end before this date + field :ends_before, T.nilable(::DateTime), { 'query_param': { 'field_name': 'ends_before' } } + # Filter shifts that start after this date + field :starts_after, T.nilable(::DateTime), { 'query_param': { 'field_name': 'starts_after' } } + # Filter to select shifts by status + field :status, T.nilable(Models::Operations::HrisListShiftsQueryParamStatus), { 'query_param': { 'field_name': 'status' } } + # Use a string with a date to only select results updated after that given date + field :updated_after, T.nilable(::String), { 'query_param': { 'field_name': 'updated_after' } } + + + sig { params(employee_id: T.nilable(::String), ends_before: T.nilable(::DateTime), starts_after: T.nilable(::DateTime), status: T.nilable(Models::Operations::HrisListShiftsQueryParamStatus), updated_after: T.nilable(::String)).void } + def initialize(employee_id: nil, ends_before: nil, starts_after: nil, status: nil, updated_after: nil) + @employee_id = employee_id + @ends_before = ends_before + @starts_after = starts_after + @status = status + @updated_after = updated_after + end + + def ==(other) + return false unless other.is_a? self.class + return false unless @employee_id == other.employee_id + return false unless @ends_before == other.ends_before + return false unless @starts_after == other.starts_after + return false unless @status == other.status + return false unless @updated_after == other.updated_after + true + end + end + end + end +end diff --git a/lib/stack_one/models/operations/hris_list_shifts_queryparam_status.rb b/lib/stack_one/models/operations/hris_list_shifts_queryparam_status.rb new file mode 100644 index 00000000..048bdd09 --- /dev/null +++ b/lib/stack_one/models/operations/hris_list_shifts_queryparam_status.rb @@ -0,0 +1,23 @@ +# Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +# typed: true +# frozen_string_literal: true + + +module StackOne + module Models + module Operations + + # HrisListShiftsQueryParamStatus - Filter to select shifts by status + class HrisListShiftsQueryParamStatus < T::Enum + enums do + DRAFT = new('draft') + PUBLISHED = new('published') + CONFIRMED = new('confirmed') + CANCELLED = new('cancelled') + UNMAPPED_VALUE = new('unmapped_value') + end + end + end + end +end diff --git a/lib/stack_one/models/operations/hris_list_shifts_request.rb b/lib/stack_one/models/operations/hris_list_shifts_request.rb new file mode 100644 index 00000000..a8b1c445 --- /dev/null +++ b/lib/stack_one/models/operations/hris_list_shifts_request.rb @@ -0,0 +1,69 @@ +# Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +# typed: true +# frozen_string_literal: true + + +module StackOne + module Models + module Operations + + + class HrisListShiftsRequest + extend T::Sig + include Crystalline::MetadataFields + + # The account identifier + field :x_account_id, ::String, { 'header': { 'field_name': 'x-account-id', 'style': 'simple', 'explode': false } } + # The comma separated list of fields to return in the response (if empty, all fields are returned) + field :fields_, T.nilable(::String), { 'query_param': { 'field_name': 'fields', 'style': 'form', 'explode': true } } + # HRIS Shifts filters + field :filter, T.nilable(Models::Operations::HrisListShiftsQueryParamFilter), { 'query_param': { 'field_name': 'filter', 'style': 'deepObject', 'explode': true } } + # The unified cursor + field :next_, T.nilable(::String), { 'query_param': { 'field_name': 'next', 'style': 'form', 'explode': true } } + # The page number of the results to fetch + # + # @deprecated true: This will be removed in a future release, please migrate away from it as soon as possible. + field :page, T.nilable(::String), { 'query_param': { 'field_name': 'page', 'style': 'form', 'explode': true } } + # The number of results per page (default value is 25) + field :page_size, T.nilable(::String), { 'query_param': { 'field_name': 'page_size', 'style': 'form', 'explode': true } } + # Query parameters that can be used to pass through parameters to the underlying provider request by surrounding them with 'proxy' key + field :proxy, T.nilable(T::Hash[Symbol, ::Object]), { 'query_param': { 'field_name': 'proxy', 'style': 'deepObject', 'explode': true } } + # Indicates that the raw request result should be returned in addition to the mapped result (default value is false) + field :raw, T.nilable(T::Boolean), { 'query_param': { 'field_name': 'raw', 'style': 'form', 'explode': true } } + # Use a string with a date to only select results updated after that given date + # + # @deprecated true: This will be removed in a future release, please migrate away from it as soon as possible. + field :updated_after, T.nilable(::String), { 'query_param': { 'field_name': 'updated_after', 'style': 'form', 'explode': true } } + + + sig { params(x_account_id: ::String, fields_: T.nilable(::String), filter: T.nilable(Models::Operations::HrisListShiftsQueryParamFilter), next_: T.nilable(::String), page: T.nilable(::String), page_size: T.nilable(::String), proxy: T.nilable(T::Hash[Symbol, ::Object]), raw: T.nilable(T::Boolean), updated_after: T.nilable(::String)).void } + def initialize(x_account_id: nil, fields_: nil, filter: nil, next_: nil, page: nil, page_size: nil, proxy: nil, raw: nil, updated_after: nil) + @x_account_id = x_account_id + @fields_ = fields_ + @filter = filter + @next_ = next_ + @page = page + @page_size = page_size + @proxy = proxy + @raw = raw + @updated_after = updated_after + end + + def ==(other) + return false unless other.is_a? self.class + return false unless @x_account_id == other.x_account_id + return false unless @fields_ == other.fields_ + return false unless @filter == other.filter + return false unless @next_ == other.next_ + return false unless @page == other.page + return false unless @page_size == other.page_size + return false unless @proxy == other.proxy + return false unless @raw == other.raw + return false unless @updated_after == other.updated_after + true + end + end + end + end +end diff --git a/lib/stack_one/models/operations/hris_list_shifts_response.rb b/lib/stack_one/models/operations/hris_list_shifts_response.rb new file mode 100644 index 00000000..bb13344f --- /dev/null +++ b/lib/stack_one/models/operations/hris_list_shifts_response.rb @@ -0,0 +1,49 @@ +# Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +# typed: true +# frozen_string_literal: true + + +module StackOne + module Models + module Operations + + + class HrisListShiftsResponse + extend T::Sig + include Crystalline::MetadataFields + + # HTTP response content type for this operation + field :content_type, ::String + + field :headers, T::Hash[Symbol, T::Array[::String]] + # Raw HTTP response; suitable for custom response parsing + field :raw_response, ::Faraday::Response + # HTTP response status code for this operation + field :status_code, ::Integer + # The list of shifts was retrieved. + field :hris_shifts_paginated, T.nilable(Models::Shared::HrisShiftsPaginated) + + + sig { params(content_type: ::String, headers: T::Hash[Symbol, T::Array[::String]], raw_response: ::Faraday::Response, status_code: ::Integer, hris_shifts_paginated: T.nilable(Models::Shared::HrisShiftsPaginated)).void } + def initialize(content_type: nil, headers: nil, raw_response: nil, status_code: nil, hris_shifts_paginated: nil) + @content_type = content_type + @headers = headers + @raw_response = raw_response + @status_code = status_code + @hris_shifts_paginated = hris_shifts_paginated + end + + def ==(other) + return false unless other.is_a? self.class + return false unless @content_type == other.content_type + return false unless @headers == other.headers + return false unless @raw_response == other.raw_response + return false unless @status_code == other.status_code + return false unless @hris_shifts_paginated == other.hris_shifts_paginated + true + end + end + end + end +end diff --git a/lib/stack_one/models/shared.rb b/lib/stack_one/models/shared.rb index 195d263d..50c68c7c 100644 --- a/lib/stack_one/models/shared.rb +++ b/lib/stack_one/models/shared.rb @@ -692,6 +692,24 @@ module Shared autoload :HrisDocumentsUploadRequestDtoSourceValue, 'stack_one/models/shared/hrisdocumentsuploadrequestdto_source_value.rb' autoload :HrisDocumentsUploadRequestDtoValue, 'stack_one/models/shared/hrisdocumentsuploadrequestdto_value.rb' autoload :HrisInviteEmployeeRequestDto, 'stack_one/models/shared/hrisinviteemployeerequestdto.rb' + autoload :HrisShift, 'stack_one/models/shared/hrisshift.rb' + autoload :HrisShiftResult, 'stack_one/models/shared/hrisshiftresult.rb' + autoload :HrisShiftResult4, 'stack_one/models/shared/hrisshiftresult_4.rb' + autoload :HrisShiftResultSchemas4, 'stack_one/models/shared/hrisshiftresult_schemas_4.rb' + autoload :HrisShiftResultSchemasSourceValue, 'stack_one/models/shared/hrisshiftresult_schemas_source_value.rb' + autoload :HrisShiftResultSchemasValue, 'stack_one/models/shared/hrisshiftresult_schemas_value.rb' + autoload :HrisShiftResultApprovalStatus, 'stack_one/models/shared/hrisshiftresult_approval_status.rb' + autoload :HrisShiftResultSourceValue, 'stack_one/models/shared/hrisshiftresult_source_value.rb' + autoload :HrisShiftResultStatus, 'stack_one/models/shared/hrisshiftresult_status.rb' + autoload :HrisShiftResultValue, 'stack_one/models/shared/hrisshiftresult_value.rb' + autoload :HrisShift4, 'stack_one/models/shared/hrisshift_4.rb' + autoload :HrisShiftSchemas4, 'stack_one/models/shared/hrisshift_schemas_4.rb' + autoload :HrisShiftSchemasSourceValue, 'stack_one/models/shared/hrisshift_schemas_source_value.rb' + autoload :HrisShiftSchemasValue, 'stack_one/models/shared/hrisshift_schemas_value.rb' + autoload :HrisShiftSourceValue, 'stack_one/models/shared/hrisshift_source_value.rb' + autoload :HrisShiftStatus, 'stack_one/models/shared/hrisshift_status.rb' + autoload :HrisShiftValue, 'stack_one/models/shared/hrisshift_value.rb' + autoload :HrisShiftsPaginated, 'stack_one/models/shared/hrisshiftspaginated.rb' autoload :HrisUpdateEmployeeRequestDto, 'stack_one/models/shared/hrisupdateemployeerequestdto.rb' autoload :HrisUpdateEmployeeRequestDto4, 'stack_one/models/shared/hrisupdateemployeerequestdto_4.rb' autoload :HrisUpdateEmployeeRequestDtoSchemas4, 'stack_one/models/shared/hrisupdateemployeerequestdto_schemas_4.rb' @@ -1083,6 +1101,7 @@ module Shared autoload :ScorecardsPaginated, 'stack_one/models/shared/scorecardspaginated.rb' autoload :ScorecardsResult, 'stack_one/models/shared/scorecardsresult.rb' autoload :Security, 'stack_one/models/shared/security.rb' + autoload :ShiftBreak, 'stack_one/models/shared/shiftbreak.rb' autoload :SkillResult, 'stack_one/models/shared/skillresult.rb' autoload :Skills, 'stack_one/models/shared/skills.rb' autoload :SkillsPaginated, 'stack_one/models/shared/skillspaginated.rb' @@ -1236,6 +1255,7 @@ module Shared autoload :Active, 'stack_one/models/shared/active.rb' autoload :Actor, 'stack_one/models/shared/actor.rb' autoload :ApplicationStatus, 'stack_one/models/shared/application_status.rb' + autoload :ApprovalStatus, 'stack_one/models/shared/approval_status.rb' autoload :Archived, 'stack_one/models/shared/archived.rb' autoload :Avatar, 'stack_one/models/shared/avatar.rb' autoload :BalanceUnit, 'stack_one/models/shared/balance_unit.rb' @@ -1250,6 +1270,7 @@ module Shared autoload :CostCenter, 'stack_one/models/shared/cost_center.rb' autoload :Country, 'stack_one/models/shared/country.rb' autoload :Credentials, 'stack_one/models/shared/credentials.rb' + autoload :Data, 'stack_one/models/shared/data.rb' autoload :Description, 'stack_one/models/shared/description.rb' autoload :Division, 'stack_one/models/shared/division.rb' autoload :Document, 'stack_one/models/shared/document.rb' diff --git a/lib/stack_one/models/shared/approval_status.rb b/lib/stack_one/models/shared/approval_status.rb new file mode 100644 index 00000000..f936414f --- /dev/null +++ b/lib/stack_one/models/shared/approval_status.rb @@ -0,0 +1,37 @@ +# Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +# typed: true +# frozen_string_literal: true + + +module StackOne + module Models + module Shared + + # The approval status of the shift + class ApprovalStatus + extend T::Sig + include Crystalline::MetadataFields + + + field :source_value, T.nilable(T.any(::String, ::Float, T::Boolean, Models::Shared::HrisShift4, T::Array[::Object])), { 'format_json': { 'letter_case': ::StackOne::Utils.field_name('source_value') } } + # The approval status of the shift + field :value, T.nilable(Models::Shared::HrisShiftValue), { 'format_json': { 'letter_case': ::StackOne::Utils.field_name('value'), 'decoder': Utils.enum_from_string(Models::Shared::HrisShiftValue, true) } } + + + sig { params(source_value: T.nilable(T.any(::String, ::Float, T::Boolean, Models::Shared::HrisShift4, T::Array[::Object])), value: T.nilable(Models::Shared::HrisShiftValue)).void } + def initialize(source_value: nil, value: nil) + @source_value = source_value + @value = value + end + + def ==(other) + return false unless other.is_a? self.class + return false unless @source_value == other.source_value + return false unless @value == other.value + true + end + end + end + end +end diff --git a/lib/stack_one/models/shared/data.rb b/lib/stack_one/models/shared/data.rb new file mode 100644 index 00000000..ad714bf6 --- /dev/null +++ b/lib/stack_one/models/shared/data.rb @@ -0,0 +1,81 @@ +# Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +# typed: true +# frozen_string_literal: true + + +module StackOne + module Models + module Shared + + + class Data + extend T::Sig + include Crystalline::MetadataFields + + # The approval status of the shift + field :approval_status, T.nilable(Models::Shared::HrisShiftResultApprovalStatus), { 'format_json': { 'letter_case': ::StackOne::Utils.field_name('approval_status') } } + # The total break duration for this shift in ISO 8601 duration format + field :break_duration, T.nilable(::String), { 'format_json': { 'letter_case': ::StackOne::Utils.field_name('break_duration') } } + # The breaks taken during this shift + field :breaks, T.nilable(T::Array[Models::Shared::ShiftBreak]), { 'format_json': { 'letter_case': ::StackOne::Utils.field_name('breaks') } } + # The company ID associated with this shift + field :company_id, T.nilable(::String), { 'format_json': { 'letter_case': ::StackOne::Utils.field_name('company_id') } } + # The date and time the shift was created + field :created_at, T.nilable(::DateTime), { 'format_json': { 'letter_case': ::StackOne::Utils.field_name('created_at'), 'decoder': Utils.datetime_from_iso_format(true) } } + # The employee ID associated with this shift + field :employee_id, T.nilable(::String), { 'format_json': { 'letter_case': ::StackOne::Utils.field_name('employee_id') } } + # The end time of the shift + field :end_time, T.nilable(::DateTime), { 'format_json': { 'letter_case': ::StackOne::Utils.field_name('end_time'), 'decoder': Utils.datetime_from_iso_format(true) } } + # Unique identifier + field :id, T.nilable(::String), { 'format_json': { 'letter_case': ::StackOne::Utils.field_name('id') } } + # The location ID where this shift takes place + field :location_id, T.nilable(::String), { 'format_json': { 'letter_case': ::StackOne::Utils.field_name('location_id') } } + # Provider's unique identifier + field :remote_id, T.nilable(::String), { 'format_json': { 'letter_case': ::StackOne::Utils.field_name('remote_id') } } + # The start time of the shift + field :start_time, T.nilable(::DateTime), { 'format_json': { 'letter_case': ::StackOne::Utils.field_name('start_time'), 'decoder': Utils.datetime_from_iso_format(true) } } + # The status of the shift + field :status, T.nilable(Models::Shared::HrisShiftResultStatus), { 'format_json': { 'letter_case': ::StackOne::Utils.field_name('status') } } + # The date and time the shift was last updated + field :updated_at, T.nilable(::DateTime), { 'format_json': { 'letter_case': ::StackOne::Utils.field_name('updated_at'), 'decoder': Utils.datetime_from_iso_format(true) } } + + + sig { params(approval_status: T.nilable(Models::Shared::HrisShiftResultApprovalStatus), break_duration: T.nilable(::String), breaks: T.nilable(T::Array[Models::Shared::ShiftBreak]), company_id: T.nilable(::String), created_at: T.nilable(::DateTime), employee_id: T.nilable(::String), end_time: T.nilable(::DateTime), id: T.nilable(::String), location_id: T.nilable(::String), remote_id: T.nilable(::String), start_time: T.nilable(::DateTime), status: T.nilable(Models::Shared::HrisShiftResultStatus), updated_at: T.nilable(::DateTime)).void } + def initialize(approval_status: nil, break_duration: nil, breaks: nil, company_id: nil, created_at: nil, employee_id: nil, end_time: nil, id: nil, location_id: nil, remote_id: nil, start_time: nil, status: nil, updated_at: nil) + @approval_status = approval_status + @break_duration = break_duration + @breaks = breaks + @company_id = company_id + @created_at = created_at + @employee_id = employee_id + @end_time = end_time + @id = id + @location_id = location_id + @remote_id = remote_id + @start_time = start_time + @status = status + @updated_at = updated_at + end + + def ==(other) + return false unless other.is_a? self.class + return false unless @approval_status == other.approval_status + return false unless @break_duration == other.break_duration + return false unless @breaks == other.breaks + return false unless @company_id == other.company_id + return false unless @created_at == other.created_at + return false unless @employee_id == other.employee_id + return false unless @end_time == other.end_time + return false unless @id == other.id + return false unless @location_id == other.location_id + return false unless @remote_id == other.remote_id + return false unless @start_time == other.start_time + return false unless @status == other.status + return false unless @updated_at == other.updated_at + true + end + end + end + end +end diff --git a/lib/stack_one/models/shared/hrisshift.rb b/lib/stack_one/models/shared/hrisshift.rb new file mode 100644 index 00000000..3f5d0a66 --- /dev/null +++ b/lib/stack_one/models/shared/hrisshift.rb @@ -0,0 +1,81 @@ +# Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +# typed: true +# frozen_string_literal: true + + +module StackOne + module Models + module Shared + + + class HrisShift + extend T::Sig + include Crystalline::MetadataFields + + # The approval status of the shift + field :approval_status, T.nilable(Models::Shared::ApprovalStatus), { 'format_json': { 'letter_case': ::StackOne::Utils.field_name('approval_status') } } + # The total break duration for this shift in ISO 8601 duration format + field :break_duration, T.nilable(::String), { 'format_json': { 'letter_case': ::StackOne::Utils.field_name('break_duration') } } + # The breaks taken during this shift + field :breaks, T.nilable(T::Array[Models::Shared::ShiftBreak]), { 'format_json': { 'letter_case': ::StackOne::Utils.field_name('breaks') } } + # The company ID associated with this shift + field :company_id, T.nilable(::String), { 'format_json': { 'letter_case': ::StackOne::Utils.field_name('company_id') } } + # The date and time the shift was created + field :created_at, T.nilable(::DateTime), { 'format_json': { 'letter_case': ::StackOne::Utils.field_name('created_at'), 'decoder': Utils.datetime_from_iso_format(true) } } + # The employee ID associated with this shift + field :employee_id, T.nilable(::String), { 'format_json': { 'letter_case': ::StackOne::Utils.field_name('employee_id') } } + # The end time of the shift + field :end_time, T.nilable(::DateTime), { 'format_json': { 'letter_case': ::StackOne::Utils.field_name('end_time'), 'decoder': Utils.datetime_from_iso_format(true) } } + # Unique identifier + field :id, T.nilable(::String), { 'format_json': { 'letter_case': ::StackOne::Utils.field_name('id') } } + # The location ID where this shift takes place + field :location_id, T.nilable(::String), { 'format_json': { 'letter_case': ::StackOne::Utils.field_name('location_id') } } + # Provider's unique identifier + field :remote_id, T.nilable(::String), { 'format_json': { 'letter_case': ::StackOne::Utils.field_name('remote_id') } } + # The start time of the shift + field :start_time, T.nilable(::DateTime), { 'format_json': { 'letter_case': ::StackOne::Utils.field_name('start_time'), 'decoder': Utils.datetime_from_iso_format(true) } } + # The status of the shift + field :status, T.nilable(Models::Shared::HrisShiftStatus), { 'format_json': { 'letter_case': ::StackOne::Utils.field_name('status') } } + # The date and time the shift was last updated + field :updated_at, T.nilable(::DateTime), { 'format_json': { 'letter_case': ::StackOne::Utils.field_name('updated_at'), 'decoder': Utils.datetime_from_iso_format(true) } } + + + sig { params(approval_status: T.nilable(Models::Shared::ApprovalStatus), break_duration: T.nilable(::String), breaks: T.nilable(T::Array[Models::Shared::ShiftBreak]), company_id: T.nilable(::String), created_at: T.nilable(::DateTime), employee_id: T.nilable(::String), end_time: T.nilable(::DateTime), id: T.nilable(::String), location_id: T.nilable(::String), remote_id: T.nilable(::String), start_time: T.nilable(::DateTime), status: T.nilable(Models::Shared::HrisShiftStatus), updated_at: T.nilable(::DateTime)).void } + def initialize(approval_status: nil, break_duration: nil, breaks: nil, company_id: nil, created_at: nil, employee_id: nil, end_time: nil, id: nil, location_id: nil, remote_id: nil, start_time: nil, status: nil, updated_at: nil) + @approval_status = approval_status + @break_duration = break_duration + @breaks = breaks + @company_id = company_id + @created_at = created_at + @employee_id = employee_id + @end_time = end_time + @id = id + @location_id = location_id + @remote_id = remote_id + @start_time = start_time + @status = status + @updated_at = updated_at + end + + def ==(other) + return false unless other.is_a? self.class + return false unless @approval_status == other.approval_status + return false unless @break_duration == other.break_duration + return false unless @breaks == other.breaks + return false unless @company_id == other.company_id + return false unless @created_at == other.created_at + return false unless @employee_id == other.employee_id + return false unless @end_time == other.end_time + return false unless @id == other.id + return false unless @location_id == other.location_id + return false unless @remote_id == other.remote_id + return false unless @start_time == other.start_time + return false unless @status == other.status + return false unless @updated_at == other.updated_at + true + end + end + end + end +end diff --git a/lib/stack_one/models/shared/hrisshift_4.rb b/lib/stack_one/models/shared/hrisshift_4.rb new file mode 100644 index 00000000..40c7f452 --- /dev/null +++ b/lib/stack_one/models/shared/hrisshift_4.rb @@ -0,0 +1,28 @@ +# Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +# typed: true +# frozen_string_literal: true + + +module StackOne + module Models + module Shared + + + class HrisShift4 + extend T::Sig + include Crystalline::MetadataFields + + + + + def initialize; end + + def ==(other) + return false unless other.is_a? self.class + true + end + end + end + end +end diff --git a/lib/stack_one/models/shared/hrisshift_schemas_4.rb b/lib/stack_one/models/shared/hrisshift_schemas_4.rb new file mode 100644 index 00000000..4276d9e4 --- /dev/null +++ b/lib/stack_one/models/shared/hrisshift_schemas_4.rb @@ -0,0 +1,28 @@ +# Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +# typed: true +# frozen_string_literal: true + + +module StackOne + module Models + module Shared + + + class HrisShiftSchemas4 + extend T::Sig + include Crystalline::MetadataFields + + + + + def initialize; end + + def ==(other) + return false unless other.is_a? self.class + true + end + end + end + end +end diff --git a/lib/stack_one/models/shared/hrisshift_schemas_source_value.rb b/lib/stack_one/models/shared/hrisshift_schemas_source_value.rb new file mode 100644 index 00000000..ad8dc130 --- /dev/null +++ b/lib/stack_one/models/shared/hrisshift_schemas_source_value.rb @@ -0,0 +1,28 @@ +# Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +# typed: true +# frozen_string_literal: true + + +module StackOne + module Models + module Shared + + + class HrisShiftSchemasSourceValue + extend T::Sig + include Crystalline::MetadataFields + + + + + def initialize; end + + def ==(other) + return false unless other.is_a? self.class + true + end + end + end + end +end diff --git a/lib/stack_one/models/shared/hrisshift_schemas_value.rb b/lib/stack_one/models/shared/hrisshift_schemas_value.rb new file mode 100644 index 00000000..2a712f88 --- /dev/null +++ b/lib/stack_one/models/shared/hrisshift_schemas_value.rb @@ -0,0 +1,23 @@ +# Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +# typed: true +# frozen_string_literal: true + + +module StackOne + module Models + module Shared + + # HrisShiftSchemasValue - The status of the shift + class HrisShiftSchemasValue < T::Enum + enums do + DRAFT = new('draft') + PUBLISHED = new('published') + CONFIRMED = new('confirmed') + CANCELLED = new('cancelled') + UNMAPPED_VALUE = new('unmapped_value') + end + end + end + end +end diff --git a/lib/stack_one/models/shared/hrisshift_source_value.rb b/lib/stack_one/models/shared/hrisshift_source_value.rb new file mode 100644 index 00000000..964eba8e --- /dev/null +++ b/lib/stack_one/models/shared/hrisshift_source_value.rb @@ -0,0 +1,28 @@ +# Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +# typed: true +# frozen_string_literal: true + + +module StackOne + module Models + module Shared + + + class HrisShiftSourceValue + extend T::Sig + include Crystalline::MetadataFields + + + + + def initialize; end + + def ==(other) + return false unless other.is_a? self.class + true + end + end + end + end +end diff --git a/lib/stack_one/models/shared/hrisshift_status.rb b/lib/stack_one/models/shared/hrisshift_status.rb new file mode 100644 index 00000000..486e8eaf --- /dev/null +++ b/lib/stack_one/models/shared/hrisshift_status.rb @@ -0,0 +1,37 @@ +# Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +# typed: true +# frozen_string_literal: true + + +module StackOne + module Models + module Shared + + # The status of the shift + class HrisShiftStatus + extend T::Sig + include Crystalline::MetadataFields + + + field :source_value, T.nilable(T.any(::String, ::Float, T::Boolean, Models::Shared::HrisShiftSchemas4, T::Array[::Object])), { 'format_json': { 'letter_case': ::StackOne::Utils.field_name('source_value') } } + # The status of the shift + field :value, T.nilable(Models::Shared::HrisShiftSchemasValue), { 'format_json': { 'letter_case': ::StackOne::Utils.field_name('value'), 'decoder': Utils.enum_from_string(Models::Shared::HrisShiftSchemasValue, true) } } + + + sig { params(source_value: T.nilable(T.any(::String, ::Float, T::Boolean, Models::Shared::HrisShiftSchemas4, T::Array[::Object])), value: T.nilable(Models::Shared::HrisShiftSchemasValue)).void } + def initialize(source_value: nil, value: nil) + @source_value = source_value + @value = value + end + + def ==(other) + return false unless other.is_a? self.class + return false unless @source_value == other.source_value + return false unless @value == other.value + true + end + end + end + end +end diff --git a/lib/stack_one/models/shared/hrisshift_value.rb b/lib/stack_one/models/shared/hrisshift_value.rb new file mode 100644 index 00000000..85ff5a85 --- /dev/null +++ b/lib/stack_one/models/shared/hrisshift_value.rb @@ -0,0 +1,22 @@ +# Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +# typed: true +# frozen_string_literal: true + + +module StackOne + module Models + module Shared + + # HrisShiftValue - The approval status of the shift + class HrisShiftValue < T::Enum + enums do + PENDING = new('pending') + APPROVED = new('approved') + REJECTED = new('rejected') + UNMAPPED_VALUE = new('unmapped_value') + end + end + end + end +end diff --git a/lib/stack_one/models/shared/hrisshiftresult.rb b/lib/stack_one/models/shared/hrisshiftresult.rb new file mode 100644 index 00000000..6d20232c --- /dev/null +++ b/lib/stack_one/models/shared/hrisshiftresult.rb @@ -0,0 +1,37 @@ +# Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +# typed: true +# frozen_string_literal: true + + +module StackOne + module Models + module Shared + + + class HrisShiftResult + extend T::Sig + include Crystalline::MetadataFields + + + field :data, T.nilable(Models::Shared::Data), { 'format_json': { 'letter_case': ::StackOne::Utils.field_name('data') } } + + field :raw, T.nilable(T::Array[Models::Shared::RawResponse]), { 'format_json': { 'letter_case': ::StackOne::Utils.field_name('raw') } } + + + sig { params(data: T.nilable(Models::Shared::Data), raw: T.nilable(T::Array[Models::Shared::RawResponse])).void } + def initialize(data: nil, raw: nil) + @data = data + @raw = raw + end + + def ==(other) + return false unless other.is_a? self.class + return false unless @data == other.data + return false unless @raw == other.raw + true + end + end + end + end +end diff --git a/lib/stack_one/models/shared/hrisshiftresult_4.rb b/lib/stack_one/models/shared/hrisshiftresult_4.rb new file mode 100644 index 00000000..a13fd0c5 --- /dev/null +++ b/lib/stack_one/models/shared/hrisshiftresult_4.rb @@ -0,0 +1,28 @@ +# Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +# typed: true +# frozen_string_literal: true + + +module StackOne + module Models + module Shared + + + class HrisShiftResult4 + extend T::Sig + include Crystalline::MetadataFields + + + + + def initialize; end + + def ==(other) + return false unless other.is_a? self.class + true + end + end + end + end +end diff --git a/lib/stack_one/models/shared/hrisshiftresult_approval_status.rb b/lib/stack_one/models/shared/hrisshiftresult_approval_status.rb new file mode 100644 index 00000000..7b761e82 --- /dev/null +++ b/lib/stack_one/models/shared/hrisshiftresult_approval_status.rb @@ -0,0 +1,37 @@ +# Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +# typed: true +# frozen_string_literal: true + + +module StackOne + module Models + module Shared + + # The approval status of the shift + class HrisShiftResultApprovalStatus + extend T::Sig + include Crystalline::MetadataFields + + + field :source_value, T.nilable(T.any(::String, ::Float, T::Boolean, Models::Shared::HrisShiftResult4, T::Array[::Object])), { 'format_json': { 'letter_case': ::StackOne::Utils.field_name('source_value') } } + # The approval status of the shift + field :value, T.nilable(Models::Shared::HrisShiftResultValue), { 'format_json': { 'letter_case': ::StackOne::Utils.field_name('value'), 'decoder': Utils.enum_from_string(Models::Shared::HrisShiftResultValue, true) } } + + + sig { params(source_value: T.nilable(T.any(::String, ::Float, T::Boolean, Models::Shared::HrisShiftResult4, T::Array[::Object])), value: T.nilable(Models::Shared::HrisShiftResultValue)).void } + def initialize(source_value: nil, value: nil) + @source_value = source_value + @value = value + end + + def ==(other) + return false unless other.is_a? self.class + return false unless @source_value == other.source_value + return false unless @value == other.value + true + end + end + end + end +end diff --git a/lib/stack_one/models/shared/hrisshiftresult_schemas_4.rb b/lib/stack_one/models/shared/hrisshiftresult_schemas_4.rb new file mode 100644 index 00000000..c3a4062f --- /dev/null +++ b/lib/stack_one/models/shared/hrisshiftresult_schemas_4.rb @@ -0,0 +1,28 @@ +# Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +# typed: true +# frozen_string_literal: true + + +module StackOne + module Models + module Shared + + + class HrisShiftResultSchemas4 + extend T::Sig + include Crystalline::MetadataFields + + + + + def initialize; end + + def ==(other) + return false unless other.is_a? self.class + true + end + end + end + end +end diff --git a/lib/stack_one/models/shared/hrisshiftresult_schemas_source_value.rb b/lib/stack_one/models/shared/hrisshiftresult_schemas_source_value.rb new file mode 100644 index 00000000..76af3062 --- /dev/null +++ b/lib/stack_one/models/shared/hrisshiftresult_schemas_source_value.rb @@ -0,0 +1,28 @@ +# Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +# typed: true +# frozen_string_literal: true + + +module StackOne + module Models + module Shared + + + class HrisShiftResultSchemasSourceValue + extend T::Sig + include Crystalline::MetadataFields + + + + + def initialize; end + + def ==(other) + return false unless other.is_a? self.class + true + end + end + end + end +end diff --git a/lib/stack_one/models/shared/hrisshiftresult_schemas_value.rb b/lib/stack_one/models/shared/hrisshiftresult_schemas_value.rb new file mode 100644 index 00000000..a62bf690 --- /dev/null +++ b/lib/stack_one/models/shared/hrisshiftresult_schemas_value.rb @@ -0,0 +1,23 @@ +# Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +# typed: true +# frozen_string_literal: true + + +module StackOne + module Models + module Shared + + # HrisShiftResultSchemasValue - The status of the shift + class HrisShiftResultSchemasValue < T::Enum + enums do + DRAFT = new('draft') + PUBLISHED = new('published') + CONFIRMED = new('confirmed') + CANCELLED = new('cancelled') + UNMAPPED_VALUE = new('unmapped_value') + end + end + end + end +end diff --git a/lib/stack_one/models/shared/hrisshiftresult_source_value.rb b/lib/stack_one/models/shared/hrisshiftresult_source_value.rb new file mode 100644 index 00000000..20b8eaf1 --- /dev/null +++ b/lib/stack_one/models/shared/hrisshiftresult_source_value.rb @@ -0,0 +1,28 @@ +# Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +# typed: true +# frozen_string_literal: true + + +module StackOne + module Models + module Shared + + + class HrisShiftResultSourceValue + extend T::Sig + include Crystalline::MetadataFields + + + + + def initialize; end + + def ==(other) + return false unless other.is_a? self.class + true + end + end + end + end +end diff --git a/lib/stack_one/models/shared/hrisshiftresult_status.rb b/lib/stack_one/models/shared/hrisshiftresult_status.rb new file mode 100644 index 00000000..d5897d5d --- /dev/null +++ b/lib/stack_one/models/shared/hrisshiftresult_status.rb @@ -0,0 +1,37 @@ +# Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +# typed: true +# frozen_string_literal: true + + +module StackOne + module Models + module Shared + + # The status of the shift + class HrisShiftResultStatus + extend T::Sig + include Crystalline::MetadataFields + + + field :source_value, T.nilable(T.any(::String, ::Float, T::Boolean, Models::Shared::HrisShiftResultSchemas4, T::Array[::Object])), { 'format_json': { 'letter_case': ::StackOne::Utils.field_name('source_value') } } + # The status of the shift + field :value, T.nilable(Models::Shared::HrisShiftResultSchemasValue), { 'format_json': { 'letter_case': ::StackOne::Utils.field_name('value'), 'decoder': Utils.enum_from_string(Models::Shared::HrisShiftResultSchemasValue, true) } } + + + sig { params(source_value: T.nilable(T.any(::String, ::Float, T::Boolean, Models::Shared::HrisShiftResultSchemas4, T::Array[::Object])), value: T.nilable(Models::Shared::HrisShiftResultSchemasValue)).void } + def initialize(source_value: nil, value: nil) + @source_value = source_value + @value = value + end + + def ==(other) + return false unless other.is_a? self.class + return false unless @source_value == other.source_value + return false unless @value == other.value + true + end + end + end + end +end diff --git a/lib/stack_one/models/shared/hrisshiftresult_value.rb b/lib/stack_one/models/shared/hrisshiftresult_value.rb new file mode 100644 index 00000000..a952779c --- /dev/null +++ b/lib/stack_one/models/shared/hrisshiftresult_value.rb @@ -0,0 +1,22 @@ +# Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +# typed: true +# frozen_string_literal: true + + +module StackOne + module Models + module Shared + + # HrisShiftResultValue - The approval status of the shift + class HrisShiftResultValue < T::Enum + enums do + PENDING = new('pending') + APPROVED = new('approved') + REJECTED = new('rejected') + UNMAPPED_VALUE = new('unmapped_value') + end + end + end + end +end diff --git a/lib/stack_one/models/shared/hrisshiftspaginated.rb b/lib/stack_one/models/shared/hrisshiftspaginated.rb new file mode 100644 index 00000000..9ec4fc14 --- /dev/null +++ b/lib/stack_one/models/shared/hrisshiftspaginated.rb @@ -0,0 +1,41 @@ +# Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +# typed: true +# frozen_string_literal: true + + +module StackOne + module Models + module Shared + + + class HrisShiftsPaginated + extend T::Sig + include Crystalline::MetadataFields + + + field :data, T.nilable(T::Array[Models::Shared::HrisShift]), { 'format_json': { 'letter_case': ::StackOne::Utils.field_name('data') } } + + field :next_, T.nilable(::String), { 'format_json': { 'letter_case': ::StackOne::Utils.field_name('next') } } + + field :raw, T.nilable(T::Array[Models::Shared::RawResponse]), { 'format_json': { 'letter_case': ::StackOne::Utils.field_name('raw') } } + + + sig { params(data: T.nilable(T::Array[Models::Shared::HrisShift]), next_: T.nilable(::String), raw: T.nilable(T::Array[Models::Shared::RawResponse])).void } + def initialize(data: nil, next_: nil, raw: nil) + @data = data + @next_ = next_ + @raw = raw + end + + def ==(other) + return false unless other.is_a? self.class + return false unless @data == other.data + return false unless @next_ == other.next_ + return false unless @raw == other.raw + true + end + end + end + end +end diff --git a/lib/stack_one/models/shared/shiftbreak.rb b/lib/stack_one/models/shared/shiftbreak.rb new file mode 100644 index 00000000..b6d0921c --- /dev/null +++ b/lib/stack_one/models/shared/shiftbreak.rb @@ -0,0 +1,57 @@ +# Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +# typed: true +# frozen_string_literal: true + + +module StackOne + module Models + module Shared + + + class ShiftBreak + extend T::Sig + include Crystalline::MetadataFields + + # The date and time the break was created + field :created_at, T.nilable(::DateTime), { 'format_json': { 'letter_case': ::StackOne::Utils.field_name('created_at'), 'decoder': Utils.datetime_from_iso_format(true) } } + # The duration of the break in ISO 8601 duration format + field :duration, T.nilable(::String), { 'format_json': { 'letter_case': ::StackOne::Utils.field_name('duration') } } + # The end time of the break + field :end_time, T.nilable(::DateTime), { 'format_json': { 'letter_case': ::StackOne::Utils.field_name('end_time'), 'decoder': Utils.datetime_from_iso_format(true) } } + # The unique identifier of the break + field :id, T.nilable(::String), { 'format_json': { 'letter_case': ::StackOne::Utils.field_name('id') } } + # Whether the break is paid + field :is_paid, T.nilable(T::Boolean), { 'format_json': { 'letter_case': ::StackOne::Utils.field_name('is_paid') } } + # The start time of the break + field :start_time, T.nilable(::DateTime), { 'format_json': { 'letter_case': ::StackOne::Utils.field_name('start_time'), 'decoder': Utils.datetime_from_iso_format(true) } } + # The date and time the break was last updated + field :updated_at, T.nilable(::DateTime), { 'format_json': { 'letter_case': ::StackOne::Utils.field_name('updated_at'), 'decoder': Utils.datetime_from_iso_format(true) } } + + + sig { params(created_at: T.nilable(::DateTime), duration: T.nilable(::String), end_time: T.nilable(::DateTime), id: T.nilable(::String), is_paid: T.nilable(T::Boolean), start_time: T.nilable(::DateTime), updated_at: T.nilable(::DateTime)).void } + def initialize(created_at: nil, duration: nil, end_time: nil, id: nil, is_paid: nil, start_time: nil, updated_at: nil) + @created_at = created_at + @duration = duration + @end_time = end_time + @id = id + @is_paid = is_paid + @start_time = start_time + @updated_at = updated_at + end + + def ==(other) + return false unless other.is_a? self.class + return false unless @created_at == other.created_at + return false unless @duration == other.duration + return false unless @end_time == other.end_time + return false unless @id == other.id + return false unless @is_paid == other.is_paid + return false unless @start_time == other.start_time + return false unless @updated_at == other.updated_at + true + end + end + end + end +end diff --git a/lib/stack_one/sdkconfiguration.rb b/lib/stack_one/sdkconfiguration.rb index 8ea08997..b62bb8ef 100644 --- a/lib/stack_one/sdkconfiguration.rb +++ b/lib/stack_one/sdkconfiguration.rb @@ -63,9 +63,9 @@ def initialize(client, hooks, retry_config, timeout_ms, security, security_sourc end @language = 'ruby' @openapi_doc_version = '1.0.0' - @sdk_version = '0.27.0' + @sdk_version = '0.29.0' @gen_version = '2.570.4' - @user_agent = 'speakeasy-sdk/ruby 0.27.0 2.570.4 1.0.0 stackone_client' + @user_agent = 'speakeasy-sdk/ruby 0.29.0 2.570.4 1.0.0 stackone_client' end sig { returns([String, T::Hash[Symbol, String]]) } diff --git a/stackone_client.gemspec b/stackone_client.gemspec index 1e2db42d..a26c3741 100644 --- a/stackone_client.gemspec +++ b/stackone_client.gemspec @@ -4,7 +4,7 @@ $LOAD_PATH.push File.expand_path('lib', __dir__) Gem::Specification.new do |s| s.name = 'stackone_client' - s.version = '0.27.0' + s.version = '0.29.0' s.platform = Gem::Platform::RUBY s.licenses = ['Apache-2.0'] s.summary = ''