stackone_client 0.2.36 → 0.2.37
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/stack_one/accounts.rb +4 -4
- data/lib/stack_one/ats.rb +78 -2
- data/lib/stack_one/hris.rb +76 -0
- data/lib/stack_one/lms.rb +175 -22
- data/lib/stack_one/models/operations/ats_get_application_custom_field_definition_request.rb +60 -0
- data/lib/stack_one/models/operations/ats_get_application_custom_field_definition_response.rb +33 -0
- data/lib/stack_one/models/operations/ats_get_assessments_request_request.rb +1 -1
- data/lib/stack_one/models/operations/ats_get_assessments_result_request.rb +1 -1
- data/lib/stack_one/models/operations/ats_get_candidate_custom_field_definition_request.rb +60 -0
- data/lib/stack_one/models/operations/ats_get_candidate_custom_field_definition_response.rb +33 -0
- data/lib/stack_one/models/operations/ats_list_application_custom_field_definitions_queryparam_filter.rb +24 -0
- data/lib/stack_one/models/operations/ats_list_application_custom_field_definitions_request.rb +2 -2
- data/lib/stack_one/models/operations/ats_list_application_documents_queryparam_filter.rb +24 -0
- data/lib/stack_one/models/operations/ats_list_application_documents_request.rb +2 -2
- data/lib/stack_one/models/operations/ats_list_applications_queryparam_filter.rb +5 -2
- data/lib/stack_one/models/operations/hris_get_employee_employment_request.rb +42 -0
- data/lib/stack_one/models/operations/hris_get_employee_employment_response.rb +33 -0
- data/lib/stack_one/models/operations/hris_list_employee_employments_queryparam_filter.rb +24 -0
- data/lib/stack_one/models/operations/hris_list_employee_employments_request.rb +58 -0
- data/lib/stack_one/models/operations/hris_list_employee_employments_response.rb +33 -0
- data/lib/stack_one/models/operations/lms_create_completion_request.rb +5 -2
- data/lib/stack_one/models/operations/lms_get_assignment_request.rb +39 -0
- data/lib/stack_one/models/operations/{lms_get_completion_response.rb → lms_get_assignment_response.rb} +6 -6
- data/lib/stack_one/models/operations/{lms_get_completion_request.rb → lms_get_course_request.rb} +2 -2
- data/lib/stack_one/models/operations/lms_get_course_response.rb +33 -0
- data/lib/stack_one/models/operations/lms_list_assignments_queryparam_filter.rb +24 -0
- data/lib/stack_one/models/operations/lms_list_assignments_request.rb +55 -0
- data/lib/stack_one/models/operations/lms_list_assignments_response.rb +33 -0
- data/lib/stack_one/models/operations/lms_list_completions_queryparam_filter.rb +24 -0
- data/lib/stack_one/models/operations/lms_list_completions_request.rb +55 -0
- data/lib/stack_one/models/operations/lms_list_completions_response.rb +33 -0
- data/lib/stack_one/models/operations/lms_list_courses_queryparam_filter.rb +24 -0
- data/lib/stack_one/models/operations/lms_list_courses_request.rb +52 -0
- data/lib/stack_one/models/operations/lms_list_courses_response.rb +33 -0
- data/lib/stack_one/models/operations/stackone_update_account_request.rb +4 -4
- data/lib/stack_one/models/operations.rb +26 -4
- data/lib/stack_one/models/shared/{contactscustomfields_type.rb → active.rb} +4 -4
- data/lib/stack_one/models/shared/applicationcustomfields.rb +2 -11
- data/lib/stack_one/models/shared/assessmentsresults.rb +7 -7
- data/lib/stack_one/models/shared/assessmentsresults_candidate.rb +8 -5
- data/lib/stack_one/models/shared/assessmentsresults_content_type.rb +2 -2
- data/lib/stack_one/models/shared/{employeecustomfields_value.rb → assessmentsresults_schemas_value.rb} +3 -7
- data/lib/stack_one/models/shared/assessmentsresults_value.rb +5 -3
- data/lib/stack_one/models/shared/assignment.rb +54 -0
- data/lib/stack_one/models/shared/{completionresult.rb → assignmentresult.rb} +3 -3
- data/lib/stack_one/models/shared/assignmentspaginated.rb +30 -0
- data/lib/stack_one/models/shared/{employeecustomfields_type.rb → assignmentstatusenum.rb} +4 -4
- data/lib/stack_one/models/shared/atsdocumentapimodel.rb +5 -2
- data/lib/stack_one/models/shared/campaign.rb +2 -2
- data/lib/stack_one/models/shared/candidatecustomfields.rb +2 -11
- data/lib/stack_one/models/shared/channelsenum.rb +2 -2
- data/lib/stack_one/models/shared/channelsenum_value.rb +24 -0
- data/lib/stack_one/models/shared/completion.rb +4 -10
- data/lib/stack_one/models/shared/{candidatecustomfields_type.rb → completion_result.rb} +4 -4
- data/lib/stack_one/models/shared/completionspaginated.rb +30 -0
- data/lib/stack_one/models/shared/contactscustomfields.rb +2 -11
- data/lib/stack_one/models/shared/contentblock_schemas_value.rb +3 -0
- data/lib/stack_one/models/shared/contentblock_value.rb +3 -1
- data/lib/stack_one/models/shared/course.rb +72 -0
- data/lib/stack_one/models/shared/course_schemas_value.rb +20 -0
- data/lib/stack_one/models/shared/{applicationcustomfields_type.rb → course_type.rb} +4 -4
- data/lib/stack_one/models/shared/course_value.rb +19 -0
- data/lib/stack_one/models/shared/coursepaginated.rb +33 -0
- data/lib/stack_one/models/shared/courseresult.rb +27 -0
- data/lib/stack_one/models/shared/customfielddefinition_value.rb +5 -0
- data/lib/stack_one/models/shared/customfielddefinitionresultapimodel.rb +27 -0
- data/lib/stack_one/models/shared/customfielddefinitionspaginated.rb +2 -2
- data/lib/stack_one/models/shared/document.rb +5 -2
- data/lib/stack_one/models/shared/employeecustomfields.rb +2 -11
- data/lib/stack_one/models/shared/hriscreateemployeerequestdto_home_location.rb +5 -2
- data/lib/stack_one/models/shared/hriscreateemployeerequestdto_work_location.rb +5 -2
- data/lib/stack_one/models/shared/hrisdocumentapimodel.rb +5 -2
- data/lib/stack_one/models/shared/hrisdocumentsuploadrequestdto.rb +5 -2
- data/lib/stack_one/models/shared/iamuser_avatar.rb +5 -2
- data/lib/stack_one/models/shared/job.rb +3 -3
- data/lib/stack_one/models/shared/jobposting_content.rb +5 -2
- data/lib/stack_one/models/shared/{patchaccountdto.rb → label.rb} +1 -1
- data/lib/stack_one/models/shared/linkedaccount.rb +2 -2
- data/lib/stack_one/models/shared/lmscreatecompletionrequestdto.rb +2 -11
- data/lib/stack_one/models/shared/patchaccountexternaldto.rb +51 -0
- data/lib/stack_one/models/shared/patchaccountexternaldto_credentials.rb +20 -0
- data/lib/stack_one/models/shared/patchaccountexternaldto_setup_information.rb +20 -0
- data/lib/stack_one/models/shared/result.rb +5 -5
- data/lib/stack_one/models/shared/secrets.rb +20 -0
- data/lib/stack_one/models/shared/skills.rb +33 -0
- data/lib/stack_one/models/shared/status.rb +14 -9
- data/lib/stack_one/models/shared/statusreason.rb +30 -0
- data/lib/stack_one/models/shared/unifieduploadrequestdto.rb +5 -2
- data/lib/stack_one/models/shared/value.rb +4 -8
- data/lib/stack_one/models/shared/workeligibility_document.rb +5 -2
- data/lib/stack_one/models/shared.rb +34 -23
- data/lib/stack_one/sdkconfiguration.rb +3 -3
- metadata +49 -16
- data/lib/stack_one/models/shared/applicationcustomfields_value.rb +0 -23
- data/lib/stack_one/models/shared/campaign_status.rb +0 -27
- data/lib/stack_one/models/shared/candidatecustomfields_value.rb +0 -23
- data/lib/stack_one/models/shared/contactscustomfields_value.rb +0 -23
- data/lib/stack_one/models/shared/user.rb +0 -42
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: c8ecd1f5127b9e9c3441aedcddce0a30689bc16e481d0299e05e3a2d5c6329e0
|
4
|
+
data.tar.gz: 44ea17c971f60192ce58fe3b6ef3b3d49a086626ac80707e97add5769cb6512d
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: a0028a3ecb6e648d1f21f71c8cedfa2e961fbdacd13e1b9d1905034a132f20de9cd0a6e8c8de8bfa37f4c6c546b1d726fab07f309dda76cda16ca4df632912bb
|
7
|
+
data.tar.gz: 37f9269e70215aa32d07937aa590a6e3676c5ab5e20d3cede1078cc805f274546193c1cc1431676e51025553644c13ffd1e248f2c80b7f88d80552b82ed549d8
|
data/lib/stack_one/accounts.rb
CHANGED
@@ -172,12 +172,12 @@ module StackOne
|
|
172
172
|
end
|
173
173
|
|
174
174
|
|
175
|
-
sig { params(
|
176
|
-
def update_account(
|
175
|
+
sig { params(patch_account_external_dto: ::StackOne::Shared::PatchAccountExternalDto, id: ::String).returns(::StackOne::Operations::StackoneUpdateAccountResponse) }
|
176
|
+
def update_account(patch_account_external_dto, id)
|
177
177
|
# update_account - Update Account
|
178
178
|
request = ::StackOne::Operations::StackoneUpdateAccountRequest.new(
|
179
179
|
|
180
|
-
|
180
|
+
patch_account_external_dto: patch_account_external_dto,
|
181
181
|
id: id
|
182
182
|
)
|
183
183
|
url, params = @sdk_configuration.get_server_details
|
@@ -189,7 +189,7 @@ module StackOne
|
|
189
189
|
request
|
190
190
|
)
|
191
191
|
headers = {}
|
192
|
-
req_content_type, data, form = Utils.serialize_request_body(request, :
|
192
|
+
req_content_type, data, form = Utils.serialize_request_body(request, :patch_account_external_dto, :json)
|
193
193
|
headers['content-type'] = req_content_type
|
194
194
|
raise StandardError, 'request body is required' if data.nil? && form.nil?
|
195
195
|
headers['Accept'] = 'application/json'
|
data/lib/stack_one/ats.rb
CHANGED
@@ -290,6 +290,44 @@ module StackOne
|
|
290
290
|
end
|
291
291
|
|
292
292
|
|
293
|
+
sig { params(request: T.nilable(::StackOne::Operations::AtsGetApplicationCustomFieldDefinitionRequest)).returns(::StackOne::Operations::AtsGetApplicationCustomFieldDefinitionResponse) }
|
294
|
+
def get_application_custom_field_definition(request)
|
295
|
+
# get_application_custom_field_definition - Get Application Custom Field Definition
|
296
|
+
url, params = @sdk_configuration.get_server_details
|
297
|
+
base_url = Utils.template_url(url, params)
|
298
|
+
url = Utils.generate_url(
|
299
|
+
::StackOne::Operations::AtsGetApplicationCustomFieldDefinitionRequest,
|
300
|
+
base_url,
|
301
|
+
'/unified/ats/custom_field_definitions/applications/{id}',
|
302
|
+
request
|
303
|
+
)
|
304
|
+
headers = Utils.get_headers(request)
|
305
|
+
query_params = Utils.get_query_params(::StackOne::Operations::AtsGetApplicationCustomFieldDefinitionRequest, request)
|
306
|
+
headers['Accept'] = 'application/json'
|
307
|
+
headers['user-agent'] = @sdk_configuration.user_agent
|
308
|
+
|
309
|
+
r = @sdk_configuration.client.get(url) do |req|
|
310
|
+
req.headers = headers
|
311
|
+
req.params = query_params
|
312
|
+
Utils.configure_request_security(req, @sdk_configuration.security) if !@sdk_configuration.nil? && !@sdk_configuration.security.nil?
|
313
|
+
end
|
314
|
+
|
315
|
+
content_type = r.headers.fetch('Content-Type', 'application/octet-stream')
|
316
|
+
|
317
|
+
res = ::StackOne::Operations::AtsGetApplicationCustomFieldDefinitionResponse.new(
|
318
|
+
status_code: r.status, content_type: content_type, raw_response: r
|
319
|
+
)
|
320
|
+
if r.status == 200
|
321
|
+
if Utils.match_content_type(content_type, 'application/json')
|
322
|
+
out = Utils.unmarshal_complex(r.env.response_body, ::StackOne::Shared::CustomFieldDefinitionResultApiModel)
|
323
|
+
res.custom_field_definition_result_api_model = out
|
324
|
+
end
|
325
|
+
elsif [400, 403, 412, 429, 500, 501].include?(r.status)
|
326
|
+
end
|
327
|
+
res
|
328
|
+
end
|
329
|
+
|
330
|
+
|
293
331
|
sig { params(request: T.nilable(::StackOne::Operations::AtsGetApplicationDocumentRequest)).returns(::StackOne::Operations::AtsGetApplicationDocumentResponse) }
|
294
332
|
def get_application_document(request)
|
295
333
|
# get_application_document - Get Application Document
|
@@ -594,6 +632,44 @@ module StackOne
|
|
594
632
|
end
|
595
633
|
|
596
634
|
|
635
|
+
sig { params(request: T.nilable(::StackOne::Operations::AtsGetCandidateCustomFieldDefinitionRequest)).returns(::StackOne::Operations::AtsGetCandidateCustomFieldDefinitionResponse) }
|
636
|
+
def get_candidate_custom_field_definition(request)
|
637
|
+
# get_candidate_custom_field_definition - Get Candidate Custom Field Definition
|
638
|
+
url, params = @sdk_configuration.get_server_details
|
639
|
+
base_url = Utils.template_url(url, params)
|
640
|
+
url = Utils.generate_url(
|
641
|
+
::StackOne::Operations::AtsGetCandidateCustomFieldDefinitionRequest,
|
642
|
+
base_url,
|
643
|
+
'/unified/ats/custom_field_definitions/candidates/{id}',
|
644
|
+
request
|
645
|
+
)
|
646
|
+
headers = Utils.get_headers(request)
|
647
|
+
query_params = Utils.get_query_params(::StackOne::Operations::AtsGetCandidateCustomFieldDefinitionRequest, request)
|
648
|
+
headers['Accept'] = 'application/json'
|
649
|
+
headers['user-agent'] = @sdk_configuration.user_agent
|
650
|
+
|
651
|
+
r = @sdk_configuration.client.get(url) do |req|
|
652
|
+
req.headers = headers
|
653
|
+
req.params = query_params
|
654
|
+
Utils.configure_request_security(req, @sdk_configuration.security) if !@sdk_configuration.nil? && !@sdk_configuration.security.nil?
|
655
|
+
end
|
656
|
+
|
657
|
+
content_type = r.headers.fetch('Content-Type', 'application/octet-stream')
|
658
|
+
|
659
|
+
res = ::StackOne::Operations::AtsGetCandidateCustomFieldDefinitionResponse.new(
|
660
|
+
status_code: r.status, content_type: content_type, raw_response: r
|
661
|
+
)
|
662
|
+
if r.status == 200
|
663
|
+
if Utils.match_content_type(content_type, 'application/json')
|
664
|
+
out = Utils.unmarshal_complex(r.env.response_body, ::StackOne::Shared::CustomFieldDefinitionResultApiModel)
|
665
|
+
res.custom_field_definition_result_api_model = out
|
666
|
+
end
|
667
|
+
elsif [400, 403, 412, 429, 500, 501].include?(r.status)
|
668
|
+
end
|
669
|
+
res
|
670
|
+
end
|
671
|
+
|
672
|
+
|
597
673
|
sig { params(request: T.nilable(::StackOne::Operations::AtsGetCandidateNoteRequest)).returns(::StackOne::Operations::AtsGetCandidateNoteResponse) }
|
598
674
|
def get_candidate_note(request)
|
599
675
|
# get_candidate_note - Get Candidate Note
|
@@ -1014,7 +1090,7 @@ module StackOne
|
|
1014
1090
|
|
1015
1091
|
sig { params(request: T.nilable(::StackOne::Operations::AtsListApplicationCustomFieldDefinitionsRequest)).returns(::StackOne::Operations::AtsListApplicationCustomFieldDefinitionsResponse) }
|
1016
1092
|
def list_application_custom_field_definitions(request)
|
1017
|
-
# list_application_custom_field_definitions - List
|
1093
|
+
# list_application_custom_field_definitions - List Application Custom Field Definitions
|
1018
1094
|
url, params = @sdk_configuration.get_server_details
|
1019
1095
|
base_url = Utils.template_url(url, params)
|
1020
1096
|
url = "#{base_url}/unified/ats/custom_field_definitions/applications"
|
@@ -1265,7 +1341,7 @@ module StackOne
|
|
1265
1341
|
|
1266
1342
|
sig { params(request: T.nilable(::StackOne::Operations::AtsListCandidateCustomFieldDefinitionsRequest)).returns(::StackOne::Operations::AtsListCandidateCustomFieldDefinitionsResponse) }
|
1267
1343
|
def list_candidate_custom_field_definitions(request)
|
1268
|
-
# list_candidate_custom_field_definitions - List
|
1344
|
+
# list_candidate_custom_field_definitions - List Candidate Custom Field Definitions
|
1269
1345
|
url, params = @sdk_configuration.get_server_details
|
1270
1346
|
base_url = Utils.template_url(url, params)
|
1271
1347
|
url = "#{base_url}/unified/ats/custom_field_definitions/candidates"
|
data/lib/stack_one/hris.rb
CHANGED
@@ -486,6 +486,44 @@ module StackOne
|
|
486
486
|
end
|
487
487
|
|
488
488
|
|
489
|
+
sig { params(request: T.nilable(::StackOne::Operations::HrisGetEmployeeEmploymentRequest)).returns(::StackOne::Operations::HrisGetEmployeeEmploymentResponse) }
|
490
|
+
def get_employee_employment(request)
|
491
|
+
# get_employee_employment - Get Employee Employment
|
492
|
+
url, params = @sdk_configuration.get_server_details
|
493
|
+
base_url = Utils.template_url(url, params)
|
494
|
+
url = Utils.generate_url(
|
495
|
+
::StackOne::Operations::HrisGetEmployeeEmploymentRequest,
|
496
|
+
base_url,
|
497
|
+
'/unified/hris/employees/{id}/employments/{subResourceId}',
|
498
|
+
request
|
499
|
+
)
|
500
|
+
headers = Utils.get_headers(request)
|
501
|
+
query_params = Utils.get_query_params(::StackOne::Operations::HrisGetEmployeeEmploymentRequest, request)
|
502
|
+
headers['Accept'] = 'application/json'
|
503
|
+
headers['user-agent'] = @sdk_configuration.user_agent
|
504
|
+
|
505
|
+
r = @sdk_configuration.client.get(url) do |req|
|
506
|
+
req.headers = headers
|
507
|
+
req.params = query_params
|
508
|
+
Utils.configure_request_security(req, @sdk_configuration.security) if !@sdk_configuration.nil? && !@sdk_configuration.security.nil?
|
509
|
+
end
|
510
|
+
|
511
|
+
content_type = r.headers.fetch('Content-Type', 'application/octet-stream')
|
512
|
+
|
513
|
+
res = ::StackOne::Operations::HrisGetEmployeeEmploymentResponse.new(
|
514
|
+
status_code: r.status, content_type: content_type, raw_response: r
|
515
|
+
)
|
516
|
+
if r.status == 200
|
517
|
+
if Utils.match_content_type(content_type, 'application/json')
|
518
|
+
out = Utils.unmarshal_complex(r.env.response_body, ::StackOne::Shared::EmploymentResult)
|
519
|
+
res.employment_result = out
|
520
|
+
end
|
521
|
+
elsif [400, 403, 412, 429, 500, 501].include?(r.status)
|
522
|
+
end
|
523
|
+
res
|
524
|
+
end
|
525
|
+
|
526
|
+
|
489
527
|
sig { params(request: T.nilable(::StackOne::Operations::HrisGetEmployeesTimeOffRequestRequest)).returns(::StackOne::Operations::HrisGetEmployeesTimeOffRequestResponse) }
|
490
528
|
def get_employees_time_off_request(request)
|
491
529
|
# get_employees_time_off_request - Get Employees Time Off Request
|
@@ -922,6 +960,44 @@ module StackOne
|
|
922
960
|
end
|
923
961
|
|
924
962
|
|
963
|
+
sig { params(request: T.nilable(::StackOne::Operations::HrisListEmployeeEmploymentsRequest)).returns(::StackOne::Operations::HrisListEmployeeEmploymentsResponse) }
|
964
|
+
def list_employee_employments(request)
|
965
|
+
# list_employee_employments - List Employee Employments
|
966
|
+
url, params = @sdk_configuration.get_server_details
|
967
|
+
base_url = Utils.template_url(url, params)
|
968
|
+
url = Utils.generate_url(
|
969
|
+
::StackOne::Operations::HrisListEmployeeEmploymentsRequest,
|
970
|
+
base_url,
|
971
|
+
'/unified/hris/employees/{id}/employments',
|
972
|
+
request
|
973
|
+
)
|
974
|
+
headers = Utils.get_headers(request)
|
975
|
+
query_params = Utils.get_query_params(::StackOne::Operations::HrisListEmployeeEmploymentsRequest, request)
|
976
|
+
headers['Accept'] = 'application/json'
|
977
|
+
headers['user-agent'] = @sdk_configuration.user_agent
|
978
|
+
|
979
|
+
r = @sdk_configuration.client.get(url) do |req|
|
980
|
+
req.headers = headers
|
981
|
+
req.params = query_params
|
982
|
+
Utils.configure_request_security(req, @sdk_configuration.security) if !@sdk_configuration.nil? && !@sdk_configuration.security.nil?
|
983
|
+
end
|
984
|
+
|
985
|
+
content_type = r.headers.fetch('Content-Type', 'application/octet-stream')
|
986
|
+
|
987
|
+
res = ::StackOne::Operations::HrisListEmployeeEmploymentsResponse.new(
|
988
|
+
status_code: r.status, content_type: content_type, raw_response: r
|
989
|
+
)
|
990
|
+
if r.status == 200
|
991
|
+
if Utils.match_content_type(content_type, 'application/json')
|
992
|
+
out = Utils.unmarshal_complex(r.env.response_body, ::StackOne::Shared::EmploymentsPaginated)
|
993
|
+
res.employments_paginated = out
|
994
|
+
end
|
995
|
+
elsif [400, 403, 412, 429, 500, 501].include?(r.status)
|
996
|
+
end
|
997
|
+
res
|
998
|
+
end
|
999
|
+
|
1000
|
+
|
925
1001
|
sig { params(request: T.nilable(::StackOne::Operations::HrisListEmployeeTimeOffRequestsRequest)).returns(::StackOne::Operations::HrisListEmployeeTimeOffRequestsResponse) }
|
926
1002
|
def list_employee_time_off_requests(request)
|
927
1003
|
# list_employee_time_off_requests - List Employee Time Off Requests
|
data/lib/stack_one/lms.rb
CHANGED
@@ -19,17 +19,23 @@ module StackOne
|
|
19
19
|
end
|
20
20
|
|
21
21
|
|
22
|
-
sig { params(lms_create_completion_request_dto: ::StackOne::Shared::LmsCreateCompletionRequestDto, x_account_id: ::String).returns(::StackOne::Operations::LmsCreateCompletionResponse) }
|
23
|
-
def create_completion(lms_create_completion_request_dto, x_account_id)
|
24
|
-
# create_completion - Create Completion
|
22
|
+
sig { params(lms_create_completion_request_dto: ::StackOne::Shared::LmsCreateCompletionRequestDto, id: ::String, x_account_id: ::String).returns(::StackOne::Operations::LmsCreateCompletionResponse) }
|
23
|
+
def create_completion(lms_create_completion_request_dto, id, x_account_id)
|
24
|
+
# create_completion - Create User Completion
|
25
25
|
request = ::StackOne::Operations::LmsCreateCompletionRequest.new(
|
26
26
|
|
27
27
|
lms_create_completion_request_dto: lms_create_completion_request_dto,
|
28
|
+
id: id,
|
28
29
|
x_account_id: x_account_id
|
29
30
|
)
|
30
31
|
url, params = @sdk_configuration.get_server_details
|
31
32
|
base_url = Utils.template_url(url, params)
|
32
|
-
url =
|
33
|
+
url = Utils.generate_url(
|
34
|
+
::StackOne::Operations::LmsCreateCompletionRequest,
|
35
|
+
base_url,
|
36
|
+
'/unified/lms/users/{id}/completions',
|
37
|
+
request
|
38
|
+
)
|
33
39
|
headers = Utils.get_headers(request)
|
34
40
|
req_content_type, data, form = Utils.serialize_request_body(request, :lms_create_completion_request_dto, :json)
|
35
41
|
headers['content-type'] = req_content_type
|
@@ -111,19 +117,19 @@ module StackOne
|
|
111
117
|
end
|
112
118
|
|
113
119
|
|
114
|
-
sig { params(request: T.nilable(::StackOne::Operations::
|
115
|
-
def
|
116
|
-
#
|
120
|
+
sig { params(request: T.nilable(::StackOne::Operations::LmsGetAssignmentRequest)).returns(::StackOne::Operations::LmsGetAssignmentResponse) }
|
121
|
+
def get_assignment(request)
|
122
|
+
# get_assignment - Get User Assignment
|
117
123
|
url, params = @sdk_configuration.get_server_details
|
118
124
|
base_url = Utils.template_url(url, params)
|
119
125
|
url = Utils.generate_url(
|
120
|
-
::StackOne::Operations::
|
126
|
+
::StackOne::Operations::LmsGetAssignmentRequest,
|
121
127
|
base_url,
|
122
|
-
'/unified/lms/
|
128
|
+
'/unified/lms/users/{id}/assignments/{subResourceId}',
|
123
129
|
request
|
124
130
|
)
|
125
131
|
headers = Utils.get_headers(request)
|
126
|
-
query_params = Utils.get_query_params(::StackOne::Operations::
|
132
|
+
query_params = Utils.get_query_params(::StackOne::Operations::LmsGetAssignmentRequest, request)
|
127
133
|
headers['Accept'] = 'application/json'
|
128
134
|
headers['user-agent'] = @sdk_configuration.user_agent
|
129
135
|
|
@@ -135,13 +141,13 @@ module StackOne
|
|
135
141
|
|
136
142
|
content_type = r.headers.fetch('Content-Type', 'application/octet-stream')
|
137
143
|
|
138
|
-
res = ::StackOne::Operations::
|
144
|
+
res = ::StackOne::Operations::LmsGetAssignmentResponse.new(
|
139
145
|
status_code: r.status, content_type: content_type, raw_response: r
|
140
146
|
)
|
141
147
|
if r.status == 200
|
142
148
|
if Utils.match_content_type(content_type, 'application/json')
|
143
|
-
out = Utils.unmarshal_complex(r.env.response_body, ::StackOne::Shared::
|
144
|
-
res.
|
149
|
+
out = Utils.unmarshal_complex(r.env.response_body, ::StackOne::Shared::AssignmentResult)
|
150
|
+
res.assignment_result = out
|
145
151
|
end
|
146
152
|
elsif [400, 403, 412, 429, 500, 501].include?(r.status)
|
147
153
|
end
|
@@ -149,19 +155,19 @@ module StackOne
|
|
149
155
|
end
|
150
156
|
|
151
157
|
|
152
|
-
sig { params(request: T.nilable(::StackOne::Operations::
|
153
|
-
def
|
154
|
-
#
|
158
|
+
sig { params(request: T.nilable(::StackOne::Operations::LmsGetCategoryRequest)).returns(::StackOne::Operations::LmsGetCategoryResponse) }
|
159
|
+
def get_category(request)
|
160
|
+
# get_category - Get Category
|
155
161
|
url, params = @sdk_configuration.get_server_details
|
156
162
|
base_url = Utils.template_url(url, params)
|
157
163
|
url = Utils.generate_url(
|
158
|
-
::StackOne::Operations::
|
164
|
+
::StackOne::Operations::LmsGetCategoryRequest,
|
159
165
|
base_url,
|
160
|
-
'/unified/lms/
|
166
|
+
'/unified/lms/categories/{id}',
|
161
167
|
request
|
162
168
|
)
|
163
169
|
headers = Utils.get_headers(request)
|
164
|
-
query_params = Utils.get_query_params(::StackOne::Operations::
|
170
|
+
query_params = Utils.get_query_params(::StackOne::Operations::LmsGetCategoryRequest, request)
|
165
171
|
headers['Accept'] = 'application/json'
|
166
172
|
headers['user-agent'] = @sdk_configuration.user_agent
|
167
173
|
|
@@ -173,13 +179,13 @@ module StackOne
|
|
173
179
|
|
174
180
|
content_type = r.headers.fetch('Content-Type', 'application/octet-stream')
|
175
181
|
|
176
|
-
res = ::StackOne::Operations::
|
182
|
+
res = ::StackOne::Operations::LmsGetCategoryResponse.new(
|
177
183
|
status_code: r.status, content_type: content_type, raw_response: r
|
178
184
|
)
|
179
185
|
if r.status == 200
|
180
186
|
if Utils.match_content_type(content_type, 'application/json')
|
181
|
-
out = Utils.unmarshal_complex(r.env.response_body, ::StackOne::Shared::
|
182
|
-
res.
|
187
|
+
out = Utils.unmarshal_complex(r.env.response_body, ::StackOne::Shared::CategoryResult)
|
188
|
+
res.category_result = out
|
183
189
|
end
|
184
190
|
elsif [400, 403, 412, 429, 500, 501].include?(r.status)
|
185
191
|
end
|
@@ -225,6 +231,44 @@ module StackOne
|
|
225
231
|
end
|
226
232
|
|
227
233
|
|
234
|
+
sig { params(request: T.nilable(::StackOne::Operations::LmsGetCourseRequest)).returns(::StackOne::Operations::LmsGetCourseResponse) }
|
235
|
+
def get_course(request)
|
236
|
+
# get_course - Get Course
|
237
|
+
url, params = @sdk_configuration.get_server_details
|
238
|
+
base_url = Utils.template_url(url, params)
|
239
|
+
url = Utils.generate_url(
|
240
|
+
::StackOne::Operations::LmsGetCourseRequest,
|
241
|
+
base_url,
|
242
|
+
'/unified/lms/courses/{id}',
|
243
|
+
request
|
244
|
+
)
|
245
|
+
headers = Utils.get_headers(request)
|
246
|
+
query_params = Utils.get_query_params(::StackOne::Operations::LmsGetCourseRequest, request)
|
247
|
+
headers['Accept'] = 'application/json'
|
248
|
+
headers['user-agent'] = @sdk_configuration.user_agent
|
249
|
+
|
250
|
+
r = @sdk_configuration.client.get(url) do |req|
|
251
|
+
req.headers = headers
|
252
|
+
req.params = query_params
|
253
|
+
Utils.configure_request_security(req, @sdk_configuration.security) if !@sdk_configuration.nil? && !@sdk_configuration.security.nil?
|
254
|
+
end
|
255
|
+
|
256
|
+
content_type = r.headers.fetch('Content-Type', 'application/octet-stream')
|
257
|
+
|
258
|
+
res = ::StackOne::Operations::LmsGetCourseResponse.new(
|
259
|
+
status_code: r.status, content_type: content_type, raw_response: r
|
260
|
+
)
|
261
|
+
if r.status == 200
|
262
|
+
if Utils.match_content_type(content_type, 'application/json')
|
263
|
+
out = Utils.unmarshal_complex(r.env.response_body, ::StackOne::Shared::CourseResult)
|
264
|
+
res.course_result = out
|
265
|
+
end
|
266
|
+
elsif [400, 403, 412, 429, 500, 501].include?(r.status)
|
267
|
+
end
|
268
|
+
res
|
269
|
+
end
|
270
|
+
|
271
|
+
|
228
272
|
sig { params(request: T.nilable(::StackOne::Operations::LmsGetUserRequest)).returns(::StackOne::Operations::LmsGetUserResponse) }
|
229
273
|
def get_user(request)
|
230
274
|
# get_user - Get User
|
@@ -263,6 +307,44 @@ module StackOne
|
|
263
307
|
end
|
264
308
|
|
265
309
|
|
310
|
+
sig { params(request: T.nilable(::StackOne::Operations::LmsListAssignmentsRequest)).returns(::StackOne::Operations::LmsListAssignmentsResponse) }
|
311
|
+
def list_assignments(request)
|
312
|
+
# list_assignments - List User Assignments
|
313
|
+
url, params = @sdk_configuration.get_server_details
|
314
|
+
base_url = Utils.template_url(url, params)
|
315
|
+
url = Utils.generate_url(
|
316
|
+
::StackOne::Operations::LmsListAssignmentsRequest,
|
317
|
+
base_url,
|
318
|
+
'/unified/lms/users/{id}/assignments',
|
319
|
+
request
|
320
|
+
)
|
321
|
+
headers = Utils.get_headers(request)
|
322
|
+
query_params = Utils.get_query_params(::StackOne::Operations::LmsListAssignmentsRequest, request)
|
323
|
+
headers['Accept'] = 'application/json'
|
324
|
+
headers['user-agent'] = @sdk_configuration.user_agent
|
325
|
+
|
326
|
+
r = @sdk_configuration.client.get(url) do |req|
|
327
|
+
req.headers = headers
|
328
|
+
req.params = query_params
|
329
|
+
Utils.configure_request_security(req, @sdk_configuration.security) if !@sdk_configuration.nil? && !@sdk_configuration.security.nil?
|
330
|
+
end
|
331
|
+
|
332
|
+
content_type = r.headers.fetch('Content-Type', 'application/octet-stream')
|
333
|
+
|
334
|
+
res = ::StackOne::Operations::LmsListAssignmentsResponse.new(
|
335
|
+
status_code: r.status, content_type: content_type, raw_response: r
|
336
|
+
)
|
337
|
+
if r.status == 200
|
338
|
+
if Utils.match_content_type(content_type, 'application/json')
|
339
|
+
out = Utils.unmarshal_complex(r.env.response_body, ::StackOne::Shared::AssignmentsPaginated)
|
340
|
+
res.assignments_paginated = out
|
341
|
+
end
|
342
|
+
elsif [400, 403, 412, 429, 500, 501].include?(r.status)
|
343
|
+
end
|
344
|
+
res
|
345
|
+
end
|
346
|
+
|
347
|
+
|
266
348
|
sig { params(request: T.nilable(::StackOne::Operations::LmsListCategoriesRequest)).returns(::StackOne::Operations::LmsListCategoriesResponse) }
|
267
349
|
def list_categories(request)
|
268
350
|
# list_categories - List Categories
|
@@ -296,6 +378,44 @@ module StackOne
|
|
296
378
|
end
|
297
379
|
|
298
380
|
|
381
|
+
sig { params(request: T.nilable(::StackOne::Operations::LmsListCompletionsRequest)).returns(::StackOne::Operations::LmsListCompletionsResponse) }
|
382
|
+
def list_completions(request)
|
383
|
+
# list_completions - List User Completions
|
384
|
+
url, params = @sdk_configuration.get_server_details
|
385
|
+
base_url = Utils.template_url(url, params)
|
386
|
+
url = Utils.generate_url(
|
387
|
+
::StackOne::Operations::LmsListCompletionsRequest,
|
388
|
+
base_url,
|
389
|
+
'/unified/lms/users/{id}/completions',
|
390
|
+
request
|
391
|
+
)
|
392
|
+
headers = Utils.get_headers(request)
|
393
|
+
query_params = Utils.get_query_params(::StackOne::Operations::LmsListCompletionsRequest, request)
|
394
|
+
headers['Accept'] = 'application/json'
|
395
|
+
headers['user-agent'] = @sdk_configuration.user_agent
|
396
|
+
|
397
|
+
r = @sdk_configuration.client.get(url) do |req|
|
398
|
+
req.headers = headers
|
399
|
+
req.params = query_params
|
400
|
+
Utils.configure_request_security(req, @sdk_configuration.security) if !@sdk_configuration.nil? && !@sdk_configuration.security.nil?
|
401
|
+
end
|
402
|
+
|
403
|
+
content_type = r.headers.fetch('Content-Type', 'application/octet-stream')
|
404
|
+
|
405
|
+
res = ::StackOne::Operations::LmsListCompletionsResponse.new(
|
406
|
+
status_code: r.status, content_type: content_type, raw_response: r
|
407
|
+
)
|
408
|
+
if r.status == 200
|
409
|
+
if Utils.match_content_type(content_type, 'application/json')
|
410
|
+
out = Utils.unmarshal_complex(r.env.response_body, ::StackOne::Shared::CompletionsPaginated)
|
411
|
+
res.completions_paginated = out
|
412
|
+
end
|
413
|
+
elsif [400, 403, 412, 429, 500, 501].include?(r.status)
|
414
|
+
end
|
415
|
+
res
|
416
|
+
end
|
417
|
+
|
418
|
+
|
299
419
|
sig { params(request: T.nilable(::StackOne::Operations::LmsListContentRequest)).returns(::StackOne::Operations::LmsListContentResponse) }
|
300
420
|
def list_content(request)
|
301
421
|
# list_content - List Content
|
@@ -329,6 +449,39 @@ module StackOne
|
|
329
449
|
end
|
330
450
|
|
331
451
|
|
452
|
+
sig { params(request: T.nilable(::StackOne::Operations::LmsListCoursesRequest)).returns(::StackOne::Operations::LmsListCoursesResponse) }
|
453
|
+
def list_courses(request)
|
454
|
+
# list_courses - List Courses
|
455
|
+
url, params = @sdk_configuration.get_server_details
|
456
|
+
base_url = Utils.template_url(url, params)
|
457
|
+
url = "#{base_url}/unified/lms/courses"
|
458
|
+
headers = Utils.get_headers(request)
|
459
|
+
query_params = Utils.get_query_params(::StackOne::Operations::LmsListCoursesRequest, request)
|
460
|
+
headers['Accept'] = 'application/json'
|
461
|
+
headers['user-agent'] = @sdk_configuration.user_agent
|
462
|
+
|
463
|
+
r = @sdk_configuration.client.get(url) do |req|
|
464
|
+
req.headers = headers
|
465
|
+
req.params = query_params
|
466
|
+
Utils.configure_request_security(req, @sdk_configuration.security) if !@sdk_configuration.nil? && !@sdk_configuration.security.nil?
|
467
|
+
end
|
468
|
+
|
469
|
+
content_type = r.headers.fetch('Content-Type', 'application/octet-stream')
|
470
|
+
|
471
|
+
res = ::StackOne::Operations::LmsListCoursesResponse.new(
|
472
|
+
status_code: r.status, content_type: content_type, raw_response: r
|
473
|
+
)
|
474
|
+
if r.status == 200
|
475
|
+
if Utils.match_content_type(content_type, 'application/json')
|
476
|
+
out = Utils.unmarshal_complex(r.env.response_body, ::StackOne::Shared::CoursePaginated)
|
477
|
+
res.course_paginated = out
|
478
|
+
end
|
479
|
+
elsif [400, 403, 412, 429, 500, 501].include?(r.status)
|
480
|
+
end
|
481
|
+
res
|
482
|
+
end
|
483
|
+
|
484
|
+
|
332
485
|
sig { params(request: T.nilable(::StackOne::Operations::LmsListUsersRequest)).returns(::StackOne::Operations::LmsListUsersResponse) }
|
333
486
|
def list_users(request)
|
334
487
|
# list_users - List Users
|
@@ -0,0 +1,60 @@
|
|
1
|
+
# Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
2
|
+
|
3
|
+
# typed: true
|
4
|
+
# frozen_string_literal: true
|
5
|
+
|
6
|
+
|
7
|
+
module StackOne
|
8
|
+
module Operations
|
9
|
+
|
10
|
+
|
11
|
+
class AtsGetApplicationCustomFieldDefinitionRequest < ::StackOne::Utils::FieldAugmented
|
12
|
+
extend T::Sig
|
13
|
+
|
14
|
+
|
15
|
+
field :id, ::String, { 'path_param': { 'field_name': 'id', 'style': 'simple', 'explode': false } }
|
16
|
+
# The account identifier
|
17
|
+
field :x_account_id, ::String, { 'header': { 'field_name': 'x-account-id', 'style': 'simple', 'explode': false } }
|
18
|
+
# The comma separated list of fields that will be returned in the response (if empty, all fields are returned)
|
19
|
+
field :fields_, T.nilable(::String), { 'query_param': { 'field_name': 'fields', 'style': 'form', 'explode': true } }
|
20
|
+
# Filter parameters that allow greater customisation of the list response
|
21
|
+
field :filter, T.nilable(::StackOne::Operations::Filter), { 'query_param': { 'field_name': 'filter', 'style': 'deepObject', 'explode': true } }
|
22
|
+
# The unified cursor
|
23
|
+
field :next_, T.nilable(::String), { 'query_param': { 'field_name': 'next', 'style': 'form', 'explode': true } }
|
24
|
+
# The page number of the results to fetch
|
25
|
+
#
|
26
|
+
# @deprecated true: This will be removed in a future release, please migrate away from it as soon as possible.
|
27
|
+
field :page, T.nilable(::String), { 'query_param': { 'field_name': 'page', 'style': 'form', 'explode': true } }
|
28
|
+
# The number of results per page
|
29
|
+
field :page_size, T.nilable(::String), { 'query_param': { 'field_name': 'page_size', 'style': 'form', 'explode': true } }
|
30
|
+
# Query parameters that can be used to pass through parameters to the underlying provider request by surrounding them with 'proxy' key
|
31
|
+
field :proxy, T.nilable(T::Hash[Symbol, ::Object]), { 'query_param': { 'field_name': 'proxy', 'style': 'deepObject', 'explode': true } }
|
32
|
+
# Indicates that the raw request result is returned
|
33
|
+
field :raw, T.nilable(T::Boolean), { 'query_param': { 'field_name': 'raw', 'style': 'form', 'explode': true } }
|
34
|
+
# The sync token to select the only updated results
|
35
|
+
#
|
36
|
+
# @deprecated true: This will be removed in a future release, please migrate away from it as soon as possible.
|
37
|
+
field :sync_token, T.nilable(::String), { 'query_param': { 'field_name': 'sync_token', 'style': 'form', 'explode': true } }
|
38
|
+
# Use a string with a date to only select results updated after that given date
|
39
|
+
#
|
40
|
+
# @deprecated true: This will be removed in a future release, please migrate away from it as soon as possible.
|
41
|
+
field :updated_after, T.nilable(::String), { 'query_param': { 'field_name': 'updated_after', 'style': 'form', 'explode': true } }
|
42
|
+
|
43
|
+
|
44
|
+
sig { params(id: ::String, x_account_id: ::String, fields_: T.nilable(::String), filter: T.nilable(::StackOne::Operations::Filter), 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), sync_token: T.nilable(::String), updated_after: T.nilable(::String)).void }
|
45
|
+
def initialize(id: nil, x_account_id: nil, fields_: nil, filter: nil, next_: nil, page: nil, page_size: nil, proxy: nil, raw: nil, sync_token: nil, updated_after: nil)
|
46
|
+
@id = id
|
47
|
+
@x_account_id = x_account_id
|
48
|
+
@fields_ = fields_
|
49
|
+
@filter = filter
|
50
|
+
@next_ = next_
|
51
|
+
@page = page
|
52
|
+
@page_size = page_size
|
53
|
+
@proxy = proxy
|
54
|
+
@raw = raw
|
55
|
+
@sync_token = sync_token
|
56
|
+
@updated_after = updated_after
|
57
|
+
end
|
58
|
+
end
|
59
|
+
end
|
60
|
+
end
|
@@ -0,0 +1,33 @@
|
|
1
|
+
# Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
2
|
+
|
3
|
+
# typed: true
|
4
|
+
# frozen_string_literal: true
|
5
|
+
|
6
|
+
|
7
|
+
module StackOne
|
8
|
+
module Operations
|
9
|
+
|
10
|
+
|
11
|
+
class AtsGetApplicationCustomFieldDefinitionResponse < ::StackOne::Utils::FieldAugmented
|
12
|
+
extend T::Sig
|
13
|
+
|
14
|
+
# HTTP response content type for this operation
|
15
|
+
field :content_type, ::String
|
16
|
+
# Raw HTTP response; suitable for custom response parsing
|
17
|
+
field :raw_response, ::Faraday::Response
|
18
|
+
# HTTP response status code for this operation
|
19
|
+
field :status_code, ::Integer
|
20
|
+
# The application custom field definition was retrieved.
|
21
|
+
field :custom_field_definition_result_api_model, T.nilable(::StackOne::Shared::CustomFieldDefinitionResultApiModel)
|
22
|
+
|
23
|
+
|
24
|
+
sig { params(content_type: ::String, raw_response: ::Faraday::Response, status_code: ::Integer, custom_field_definition_result_api_model: T.nilable(::StackOne::Shared::CustomFieldDefinitionResultApiModel)).void }
|
25
|
+
def initialize(content_type: nil, raw_response: nil, status_code: nil, custom_field_definition_result_api_model: nil)
|
26
|
+
@content_type = content_type
|
27
|
+
@raw_response = raw_response
|
28
|
+
@status_code = status_code
|
29
|
+
@custom_field_definition_result_api_model = custom_field_definition_result_api_model
|
30
|
+
end
|
31
|
+
end
|
32
|
+
end
|
33
|
+
end
|
@@ -15,7 +15,7 @@ module StackOne
|
|
15
15
|
field :id, ::String, { 'path_param': { 'field_name': 'id', 'style': 'simple', 'explode': false } }
|
16
16
|
# The account identifier
|
17
17
|
field :x_account_id, ::String, { 'header': { 'field_name': 'x-account-id', 'style': 'simple', 'explode': false } }
|
18
|
-
# The comma separated list of fields
|
18
|
+
# The comma separated list of fields that will be returned in the response (if empty, all fields are returned)
|
19
19
|
field :fields_, T.nilable(::String), { 'query_param': { 'field_name': 'fields', 'style': 'form', 'explode': true } }
|
20
20
|
# Query parameters that can be used to pass through parameters to the underlying provider request by surrounding them with 'proxy' key
|
21
21
|
field :proxy, T.nilable(T::Hash[Symbol, ::Object]), { 'query_param': { 'field_name': 'proxy', 'style': 'deepObject', 'explode': true } }
|
@@ -15,7 +15,7 @@ module StackOne
|
|
15
15
|
field :id, ::String, { 'path_param': { 'field_name': 'id', 'style': 'simple', 'explode': false } }
|
16
16
|
# The account identifier
|
17
17
|
field :x_account_id, ::String, { 'header': { 'field_name': 'x-account-id', 'style': 'simple', 'explode': false } }
|
18
|
-
# The comma separated list of fields
|
18
|
+
# The comma separated list of fields that will be returned in the response (if empty, all fields are returned)
|
19
19
|
field :fields_, T.nilable(::String), { 'query_param': { 'field_name': 'fields', 'style': 'form', 'explode': true } }
|
20
20
|
# Query parameters that can be used to pass through parameters to the underlying provider request by surrounding them with 'proxy' key
|
21
21
|
field :proxy, T.nilable(T::Hash[Symbol, ::Object]), { 'query_param': { 'field_name': 'proxy', 'style': 'deepObject', 'explode': true } }
|