stackone_hris_client 1.0.0 → 1.2.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (79) hide show
  1. checksums.yaml +4 -4
  2. data/Gemfile.lock +1 -1
  3. data/README.md +42 -15
  4. data/docs/Account.md +32 -0
  5. data/docs/AccountsApi.md +218 -0
  6. data/docs/CompaniesApi.md +175 -0
  7. data/docs/CompaniesPaginated.md +22 -0
  8. data/docs/Company.md +22 -0
  9. data/docs/CompanyResult.md +20 -0
  10. data/docs/ConnectSession.md +34 -0
  11. data/docs/ConnectSessionAuthenticate.md +18 -0
  12. data/docs/ConnectSessionCreate.md +28 -0
  13. data/docs/ConnectSessionToken.md +36 -0
  14. data/docs/ConnectSessionsApi.md +145 -0
  15. data/docs/Employee.md +36 -12
  16. data/docs/EmployeeResult.md +2 -2
  17. data/docs/EmployeesApi.md +19 -13
  18. data/docs/EmployeesPaginated.md +2 -2
  19. data/docs/Employment.md +34 -0
  20. data/docs/EmploymentResult.md +20 -0
  21. data/docs/EmploymentsApi.md +175 -0
  22. data/docs/EmploymentsPaginated.md +22 -0
  23. data/docs/Location.md +38 -0
  24. data/docs/LocationResult.md +20 -0
  25. data/docs/LocationsApi.md +175 -0
  26. data/docs/LocationsPaginated.md +22 -0
  27. data/gem-config.yml +4 -4
  28. data/lib/stackone_hris_client/api/accounts_api.rb +205 -0
  29. data/lib/stackone_hris_client/api/companies_api.rb +188 -0
  30. data/lib/stackone_hris_client/api/connect_sessions_api.rb +154 -0
  31. data/lib/stackone_hris_client/api/employees_api.rb +10 -4
  32. data/lib/stackone_hris_client/api/employments_api.rb +188 -0
  33. data/lib/stackone_hris_client/api/locations_api.rb +188 -0
  34. data/lib/stackone_hris_client/api_client.rb +5 -5
  35. data/lib/stackone_hris_client/api_error.rb +4 -4
  36. data/lib/stackone_hris_client/configuration.rb +13 -12
  37. data/lib/stackone_hris_client/models/account.rb +322 -0
  38. data/lib/stackone_hris_client/models/companies_paginated.rb +249 -0
  39. data/lib/stackone_hris_client/models/company.rb +237 -0
  40. data/lib/stackone_hris_client/models/company_result.rb +233 -0
  41. data/lib/stackone_hris_client/models/connect_session.rb +350 -0
  42. data/lib/stackone_hris_client/models/connect_session_authenticate.rb +225 -0
  43. data/lib/stackone_hris_client/models/connect_session_create.rb +304 -0
  44. data/lib/stackone_hris_client/models/connect_session_token.rb +364 -0
  45. data/lib/stackone_hris_client/models/employee.rb +145 -60
  46. data/lib/stackone_hris_client/models/employee_result.rb +9 -7
  47. data/lib/stackone_hris_client/models/employees_paginated.rb +9 -7
  48. data/lib/stackone_hris_client/models/employment.rb +296 -0
  49. data/lib/stackone_hris_client/models/employment_result.rb +233 -0
  50. data/lib/stackone_hris_client/models/employments_paginated.rb +249 -0
  51. data/lib/stackone_hris_client/models/location.rb +314 -0
  52. data/lib/stackone_hris_client/models/location_result.rb +233 -0
  53. data/lib/stackone_hris_client/models/locations_paginated.rb +249 -0
  54. data/lib/stackone_hris_client/version.rb +5 -5
  55. data/lib/stackone_hris_client.rb +23 -4
  56. data/spec/api/accounts_api_spec.rb +58 -0
  57. data/spec/api/companies_api_spec.rb +70 -0
  58. data/spec/api/connect_sessions_api_spec.rb +57 -0
  59. data/spec/api/employments_api_spec.rb +70 -0
  60. data/spec/api/locations_api_spec.rb +70 -0
  61. data/spec/api_client_spec.rb +32 -32
  62. data/spec/configuration_spec.rb +6 -6
  63. data/spec/models/account_spec.rb +76 -0
  64. data/spec/models/companies_paginated_spec.rb +46 -0
  65. data/spec/models/company_result_spec.rb +40 -0
  66. data/spec/models/company_spec.rb +46 -0
  67. data/spec/models/connect_session_authenticate_spec.rb +34 -0
  68. data/spec/models/connect_session_create_spec.rb +68 -0
  69. data/spec/models/connect_session_spec.rb +86 -0
  70. data/spec/models/connect_session_token_spec.rb +92 -0
  71. data/spec/models/employment_result_spec.rb +40 -0
  72. data/spec/models/employment_spec.rb +82 -0
  73. data/spec/models/employments_paginated_spec.rb +46 -0
  74. data/spec/models/location_result_spec.rb +40 -0
  75. data/spec/models/location_spec.rb +94 -0
  76. data/spec/models/locations_paginated_spec.rb +46 -0
  77. data/spec/spec_helper.rb +3 -3
  78. data/stackone_hris_client.gemspec +5 -5
  79. metadata +79 -3
@@ -0,0 +1,154 @@
1
+ =begin
2
+ #StackOne Unified API - HRIS
3
+
4
+ #The documentation for the StackOne Unified API - HRIS
5
+
6
+ The version of the OpenAPI document: 1.0.0
7
+
8
+ Generated by: https://openapi-generator.tech
9
+ OpenAPI Generator version: 6.4.0
10
+
11
+ =end
12
+
13
+ require 'cgi'
14
+
15
+ module StackOneHRIS
16
+ class ConnectSessionsApi
17
+ attr_accessor :api_client
18
+
19
+ def initialize(api_client = ApiClient.default)
20
+ @api_client = api_client
21
+ end
22
+ #
23
+ # @param connect_session_authenticate [ConnectSessionAuthenticate] The parameters to authenticate
24
+ # @param [Hash] opts the optional parameters
25
+ # @return [ConnectSession]
26
+ def connect_sessions_authenticate(connect_session_authenticate, opts = {})
27
+ data, _status_code, _headers = connect_sessions_authenticate_with_http_info(connect_session_authenticate, opts)
28
+ data
29
+ end
30
+
31
+ #
32
+ # @param connect_session_authenticate [ConnectSessionAuthenticate] The parameters to authenticate
33
+ # @param [Hash] opts the optional parameters
34
+ # @return [Array<(ConnectSession, Integer, Hash)>] ConnectSession data, response status code and response headers
35
+ def connect_sessions_authenticate_with_http_info(connect_session_authenticate, opts = {})
36
+ if @api_client.config.debugging
37
+ @api_client.config.logger.debug 'Calling API: ConnectSessionsApi.connect_sessions_authenticate ...'
38
+ end
39
+ # verify the required parameter 'connect_session_authenticate' is set
40
+ if @api_client.config.client_side_validation && connect_session_authenticate.nil?
41
+ fail ArgumentError, "Missing the required parameter 'connect_session_authenticate' when calling ConnectSessionsApi.connect_sessions_authenticate"
42
+ end
43
+ # resource path
44
+ local_var_path = '/connect_sessions/authenticate'
45
+
46
+ # query parameters
47
+ query_params = opts[:query_params] || {}
48
+
49
+ # header parameters
50
+ header_params = opts[:header_params] || {}
51
+ # HTTP header 'Accept' (if needed)
52
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
53
+ # HTTP header 'Content-Type'
54
+ content_type = @api_client.select_header_content_type(['application/json'])
55
+ if !content_type.nil?
56
+ header_params['Content-Type'] = content_type
57
+ end
58
+
59
+ # form parameters
60
+ form_params = opts[:form_params] || {}
61
+
62
+ # http body (model)
63
+ post_body = opts[:debug_body] || @api_client.object_to_http_body(connect_session_authenticate)
64
+
65
+ # return_type
66
+ return_type = opts[:debug_return_type] || 'ConnectSession'
67
+
68
+ # auth_names
69
+ auth_names = opts[:debug_auth_names] || ['basic']
70
+
71
+ new_options = opts.merge(
72
+ :operation => :"ConnectSessionsApi.connect_sessions_authenticate",
73
+ :header_params => header_params,
74
+ :query_params => query_params,
75
+ :form_params => form_params,
76
+ :body => post_body,
77
+ :auth_names => auth_names,
78
+ :return_type => return_type
79
+ )
80
+
81
+ data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
82
+ if @api_client.config.debugging
83
+ @api_client.config.logger.debug "API called: ConnectSessionsApi#connect_sessions_authenticate\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
84
+ end
85
+ return data, status_code, headers
86
+ end
87
+
88
+ #
89
+ # @param connect_session_create [ConnectSessionCreate]
90
+ # @param [Hash] opts the optional parameters
91
+ # @return [ConnectSessionToken]
92
+ def connect_sessions_create(connect_session_create, opts = {})
93
+ data, _status_code, _headers = connect_sessions_create_with_http_info(connect_session_create, opts)
94
+ data
95
+ end
96
+
97
+ #
98
+ # @param connect_session_create [ConnectSessionCreate]
99
+ # @param [Hash] opts the optional parameters
100
+ # @return [Array<(ConnectSessionToken, Integer, Hash)>] ConnectSessionToken data, response status code and response headers
101
+ def connect_sessions_create_with_http_info(connect_session_create, opts = {})
102
+ if @api_client.config.debugging
103
+ @api_client.config.logger.debug 'Calling API: ConnectSessionsApi.connect_sessions_create ...'
104
+ end
105
+ # verify the required parameter 'connect_session_create' is set
106
+ if @api_client.config.client_side_validation && connect_session_create.nil?
107
+ fail ArgumentError, "Missing the required parameter 'connect_session_create' when calling ConnectSessionsApi.connect_sessions_create"
108
+ end
109
+ # resource path
110
+ local_var_path = '/connect_sessions'
111
+
112
+ # query parameters
113
+ query_params = opts[:query_params] || {}
114
+
115
+ # header parameters
116
+ header_params = opts[:header_params] || {}
117
+ # HTTP header 'Accept' (if needed)
118
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
119
+ # HTTP header 'Content-Type'
120
+ content_type = @api_client.select_header_content_type(['application/json'])
121
+ if !content_type.nil?
122
+ header_params['Content-Type'] = content_type
123
+ end
124
+
125
+ # form parameters
126
+ form_params = opts[:form_params] || {}
127
+
128
+ # http body (model)
129
+ post_body = opts[:debug_body] || @api_client.object_to_http_body(connect_session_create)
130
+
131
+ # return_type
132
+ return_type = opts[:debug_return_type] || 'ConnectSessionToken'
133
+
134
+ # auth_names
135
+ auth_names = opts[:debug_auth_names] || ['basic']
136
+
137
+ new_options = opts.merge(
138
+ :operation => :"ConnectSessionsApi.connect_sessions_create",
139
+ :header_params => header_params,
140
+ :query_params => query_params,
141
+ :form_params => form_params,
142
+ :body => post_body,
143
+ :auth_names => auth_names,
144
+ :return_type => return_type
145
+ )
146
+
147
+ data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
148
+ if @api_client.config.debugging
149
+ @api_client.config.logger.debug "API called: ConnectSessionsApi#connect_sessions_create\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
150
+ end
151
+ return data, status_code, headers
152
+ end
153
+ end
154
+ end
@@ -1,9 +1,9 @@
1
1
  =begin
2
- #StackOne Unified API
2
+ #StackOne Unified API - HRIS
3
3
 
4
- #The documentation for the StackOne Unified API
4
+ #The documentation for the StackOne Unified API - HRIS
5
5
 
6
- The version of the OpenAPI document: 1.0
6
+ The version of the OpenAPI document: 1.0.0
7
7
 
8
8
  Generated by: https://openapi-generator.tech
9
9
  OpenAPI Generator version: 6.4.0
@@ -12,7 +12,7 @@ OpenAPI Generator version: 6.4.0
12
12
 
13
13
  require 'cgi'
14
14
 
15
- module StackOneHrisClient
15
+ module StackOneHRIS
16
16
  class EmployeesApi
17
17
  attr_accessor :api_client
18
18
 
@@ -28,6 +28,7 @@ module StackOneHrisClient
28
28
  # @option opts [Boolean] :raw Indicates that the raw request result is returned (default to false)
29
29
  # @option opts [Array<String>] :fields The list of fields to return in the response (if empty, all fields are returned)
30
30
  # @option opts [Array<String>] :expand The list of fields that will be expanded in the response
31
+ # @option opts [String] :sync_token The sync token to select the only updated results
31
32
  # @return [EmployeeResult]
32
33
  def employees_get(id, x_account_id, opts = {})
33
34
  data, _status_code, _headers = employees_get_with_http_info(id, x_account_id, opts)
@@ -43,6 +44,7 @@ module StackOneHrisClient
43
44
  # @option opts [Boolean] :raw Indicates that the raw request result is returned (default to false)
44
45
  # @option opts [Array<String>] :fields The list of fields to return in the response (if empty, all fields are returned)
45
46
  # @option opts [Array<String>] :expand The list of fields that will be expanded in the response
47
+ # @option opts [String] :sync_token The sync token to select the only updated results
46
48
  # @return [Array<(EmployeeResult, Integer, Hash)>] EmployeeResult data, response status code and response headers
47
49
  def employees_get_with_http_info(id, x_account_id, opts = {})
48
50
  if @api_client.config.debugging
@@ -66,6 +68,7 @@ module StackOneHrisClient
66
68
  query_params[:'raw'] = opts[:'raw'] if !opts[:'raw'].nil?
67
69
  query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :multi) if !opts[:'fields'].nil?
68
70
  query_params[:'expand'] = @api_client.build_collection_param(opts[:'expand'], :multi) if !opts[:'expand'].nil?
71
+ query_params[:'sync_token'] = opts[:'sync_token'] if !opts[:'sync_token'].nil?
69
72
 
70
73
  # header parameters
71
74
  header_params = opts[:header_params] || {}
@@ -110,6 +113,7 @@ module StackOneHrisClient
110
113
  # @option opts [Boolean] :raw Indicates that the raw request result is returned (default to false)
111
114
  # @option opts [Array<String>] :fields The list of fields to return in the response (if empty, all fields are returned)
112
115
  # @option opts [Array<String>] :expand The list of fields that will be expanded in the response
116
+ # @option opts [String] :sync_token The sync token to select the only updated results
113
117
  # @return [EmployeesPaginated]
114
118
  def employees_list(x_account_id, opts = {})
115
119
  data, _status_code, _headers = employees_list_with_http_info(x_account_id, opts)
@@ -124,6 +128,7 @@ module StackOneHrisClient
124
128
  # @option opts [Boolean] :raw Indicates that the raw request result is returned (default to false)
125
129
  # @option opts [Array<String>] :fields The list of fields to return in the response (if empty, all fields are returned)
126
130
  # @option opts [Array<String>] :expand The list of fields that will be expanded in the response
131
+ # @option opts [String] :sync_token The sync token to select the only updated results
127
132
  # @return [Array<(EmployeesPaginated, Integer, Hash)>] EmployeesPaginated data, response status code and response headers
128
133
  def employees_list_with_http_info(x_account_id, opts = {})
129
134
  if @api_client.config.debugging
@@ -143,6 +148,7 @@ module StackOneHrisClient
143
148
  query_params[:'raw'] = opts[:'raw'] if !opts[:'raw'].nil?
144
149
  query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :multi) if !opts[:'fields'].nil?
145
150
  query_params[:'expand'] = @api_client.build_collection_param(opts[:'expand'], :multi) if !opts[:'expand'].nil?
151
+ query_params[:'sync_token'] = opts[:'sync_token'] if !opts[:'sync_token'].nil?
146
152
 
147
153
  # header parameters
148
154
  header_params = opts[:header_params] || {}
@@ -0,0 +1,188 @@
1
+ =begin
2
+ #StackOne Unified API - HRIS
3
+
4
+ #The documentation for the StackOne Unified API - HRIS
5
+
6
+ The version of the OpenAPI document: 1.0.0
7
+
8
+ Generated by: https://openapi-generator.tech
9
+ OpenAPI Generator version: 6.4.0
10
+
11
+ =end
12
+
13
+ require 'cgi'
14
+
15
+ module StackOneHRIS
16
+ class EmploymentsApi
17
+ attr_accessor :api_client
18
+
19
+ def initialize(api_client = ApiClient.default)
20
+ @api_client = api_client
21
+ end
22
+ #
23
+ # @param id [String]
24
+ # @param x_account_id [String] The account identifier
25
+ # @param [Hash] opts the optional parameters
26
+ # @option opts [String] :page The page number of the results to fetch
27
+ # @option opts [String] :page_size The number of results per page (default to '25')
28
+ # @option opts [Boolean] :raw Indicates that the raw request result is returned (default to false)
29
+ # @option opts [Array<String>] :fields The list of fields to return in the response (if empty, all fields are returned)
30
+ # @option opts [Array<String>] :expand The list of fields that will be expanded in the response
31
+ # @option opts [String] :sync_token The sync token to select the only updated results
32
+ # @return [EmploymentResult]
33
+ def employments_get(id, x_account_id, opts = {})
34
+ data, _status_code, _headers = employments_get_with_http_info(id, x_account_id, opts)
35
+ data
36
+ end
37
+
38
+ #
39
+ # @param id [String]
40
+ # @param x_account_id [String] The account identifier
41
+ # @param [Hash] opts the optional parameters
42
+ # @option opts [String] :page The page number of the results to fetch
43
+ # @option opts [String] :page_size The number of results per page (default to '25')
44
+ # @option opts [Boolean] :raw Indicates that the raw request result is returned (default to false)
45
+ # @option opts [Array<String>] :fields The list of fields to return in the response (if empty, all fields are returned)
46
+ # @option opts [Array<String>] :expand The list of fields that will be expanded in the response
47
+ # @option opts [String] :sync_token The sync token to select the only updated results
48
+ # @return [Array<(EmploymentResult, Integer, Hash)>] EmploymentResult data, response status code and response headers
49
+ def employments_get_with_http_info(id, x_account_id, opts = {})
50
+ if @api_client.config.debugging
51
+ @api_client.config.logger.debug 'Calling API: EmploymentsApi.employments_get ...'
52
+ end
53
+ # verify the required parameter 'id' is set
54
+ if @api_client.config.client_side_validation && id.nil?
55
+ fail ArgumentError, "Missing the required parameter 'id' when calling EmploymentsApi.employments_get"
56
+ end
57
+ # verify the required parameter 'x_account_id' is set
58
+ if @api_client.config.client_side_validation && x_account_id.nil?
59
+ fail ArgumentError, "Missing the required parameter 'x_account_id' when calling EmploymentsApi.employments_get"
60
+ end
61
+ # resource path
62
+ local_var_path = '/unified/hris/employments/{id}'.sub('{' + 'id' + '}', CGI.escape(id.to_s))
63
+
64
+ # query parameters
65
+ query_params = opts[:query_params] || {}
66
+ query_params[:'page'] = opts[:'page'] if !opts[:'page'].nil?
67
+ query_params[:'page_size'] = opts[:'page_size'] if !opts[:'page_size'].nil?
68
+ query_params[:'raw'] = opts[:'raw'] if !opts[:'raw'].nil?
69
+ query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :multi) if !opts[:'fields'].nil?
70
+ query_params[:'expand'] = @api_client.build_collection_param(opts[:'expand'], :multi) if !opts[:'expand'].nil?
71
+ query_params[:'sync_token'] = opts[:'sync_token'] if !opts[:'sync_token'].nil?
72
+
73
+ # header parameters
74
+ header_params = opts[:header_params] || {}
75
+ # HTTP header 'Accept' (if needed)
76
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
77
+ header_params[:'x-account-id'] = x_account_id
78
+
79
+ # form parameters
80
+ form_params = opts[:form_params] || {}
81
+
82
+ # http body (model)
83
+ post_body = opts[:debug_body]
84
+
85
+ # return_type
86
+ return_type = opts[:debug_return_type] || 'EmploymentResult'
87
+
88
+ # auth_names
89
+ auth_names = opts[:debug_auth_names] || ['basic']
90
+
91
+ new_options = opts.merge(
92
+ :operation => :"EmploymentsApi.employments_get",
93
+ :header_params => header_params,
94
+ :query_params => query_params,
95
+ :form_params => form_params,
96
+ :body => post_body,
97
+ :auth_names => auth_names,
98
+ :return_type => return_type
99
+ )
100
+
101
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
102
+ if @api_client.config.debugging
103
+ @api_client.config.logger.debug "API called: EmploymentsApi#employments_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
104
+ end
105
+ return data, status_code, headers
106
+ end
107
+
108
+ #
109
+ # @param x_account_id [String] The account identifier
110
+ # @param [Hash] opts the optional parameters
111
+ # @option opts [String] :page The page number of the results to fetch
112
+ # @option opts [String] :page_size The number of results per page (default to '25')
113
+ # @option opts [Boolean] :raw Indicates that the raw request result is returned (default to false)
114
+ # @option opts [Array<String>] :fields The list of fields to return in the response (if empty, all fields are returned)
115
+ # @option opts [Array<String>] :expand The list of fields that will be expanded in the response
116
+ # @option opts [String] :sync_token The sync token to select the only updated results
117
+ # @return [EmploymentsPaginated]
118
+ def employments_list(x_account_id, opts = {})
119
+ data, _status_code, _headers = employments_list_with_http_info(x_account_id, opts)
120
+ data
121
+ end
122
+
123
+ #
124
+ # @param x_account_id [String] The account identifier
125
+ # @param [Hash] opts the optional parameters
126
+ # @option opts [String] :page The page number of the results to fetch
127
+ # @option opts [String] :page_size The number of results per page (default to '25')
128
+ # @option opts [Boolean] :raw Indicates that the raw request result is returned (default to false)
129
+ # @option opts [Array<String>] :fields The list of fields to return in the response (if empty, all fields are returned)
130
+ # @option opts [Array<String>] :expand The list of fields that will be expanded in the response
131
+ # @option opts [String] :sync_token The sync token to select the only updated results
132
+ # @return [Array<(EmploymentsPaginated, Integer, Hash)>] EmploymentsPaginated data, response status code and response headers
133
+ def employments_list_with_http_info(x_account_id, opts = {})
134
+ if @api_client.config.debugging
135
+ @api_client.config.logger.debug 'Calling API: EmploymentsApi.employments_list ...'
136
+ end
137
+ # verify the required parameter 'x_account_id' is set
138
+ if @api_client.config.client_side_validation && x_account_id.nil?
139
+ fail ArgumentError, "Missing the required parameter 'x_account_id' when calling EmploymentsApi.employments_list"
140
+ end
141
+ # resource path
142
+ local_var_path = '/unified/hris/employments'
143
+
144
+ # query parameters
145
+ query_params = opts[:query_params] || {}
146
+ query_params[:'page'] = opts[:'page'] if !opts[:'page'].nil?
147
+ query_params[:'page_size'] = opts[:'page_size'] if !opts[:'page_size'].nil?
148
+ query_params[:'raw'] = opts[:'raw'] if !opts[:'raw'].nil?
149
+ query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :multi) if !opts[:'fields'].nil?
150
+ query_params[:'expand'] = @api_client.build_collection_param(opts[:'expand'], :multi) if !opts[:'expand'].nil?
151
+ query_params[:'sync_token'] = opts[:'sync_token'] if !opts[:'sync_token'].nil?
152
+
153
+ # header parameters
154
+ header_params = opts[:header_params] || {}
155
+ # HTTP header 'Accept' (if needed)
156
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
157
+ header_params[:'x-account-id'] = x_account_id
158
+
159
+ # form parameters
160
+ form_params = opts[:form_params] || {}
161
+
162
+ # http body (model)
163
+ post_body = opts[:debug_body]
164
+
165
+ # return_type
166
+ return_type = opts[:debug_return_type] || 'EmploymentsPaginated'
167
+
168
+ # auth_names
169
+ auth_names = opts[:debug_auth_names] || ['basic']
170
+
171
+ new_options = opts.merge(
172
+ :operation => :"EmploymentsApi.employments_list",
173
+ :header_params => header_params,
174
+ :query_params => query_params,
175
+ :form_params => form_params,
176
+ :body => post_body,
177
+ :auth_names => auth_names,
178
+ :return_type => return_type
179
+ )
180
+
181
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
182
+ if @api_client.config.debugging
183
+ @api_client.config.logger.debug "API called: EmploymentsApi#employments_list\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
184
+ end
185
+ return data, status_code, headers
186
+ end
187
+ end
188
+ end
@@ -0,0 +1,188 @@
1
+ =begin
2
+ #StackOne Unified API - HRIS
3
+
4
+ #The documentation for the StackOne Unified API - HRIS
5
+
6
+ The version of the OpenAPI document: 1.0.0
7
+
8
+ Generated by: https://openapi-generator.tech
9
+ OpenAPI Generator version: 6.4.0
10
+
11
+ =end
12
+
13
+ require 'cgi'
14
+
15
+ module StackOneHRIS
16
+ class LocationsApi
17
+ attr_accessor :api_client
18
+
19
+ def initialize(api_client = ApiClient.default)
20
+ @api_client = api_client
21
+ end
22
+ #
23
+ # @param id [String]
24
+ # @param x_account_id [String] The account identifier
25
+ # @param [Hash] opts the optional parameters
26
+ # @option opts [String] :page The page number of the results to fetch
27
+ # @option opts [String] :page_size The number of results per page (default to '25')
28
+ # @option opts [Boolean] :raw Indicates that the raw request result is returned (default to false)
29
+ # @option opts [Array<String>] :fields The list of fields to return in the response (if empty, all fields are returned)
30
+ # @option opts [Array<String>] :expand The list of fields that will be expanded in the response
31
+ # @option opts [String] :sync_token The sync token to select the only updated results
32
+ # @return [LocationResult]
33
+ def hris_locations_get(id, x_account_id, opts = {})
34
+ data, _status_code, _headers = hris_locations_get_with_http_info(id, x_account_id, opts)
35
+ data
36
+ end
37
+
38
+ #
39
+ # @param id [String]
40
+ # @param x_account_id [String] The account identifier
41
+ # @param [Hash] opts the optional parameters
42
+ # @option opts [String] :page The page number of the results to fetch
43
+ # @option opts [String] :page_size The number of results per page (default to '25')
44
+ # @option opts [Boolean] :raw Indicates that the raw request result is returned (default to false)
45
+ # @option opts [Array<String>] :fields The list of fields to return in the response (if empty, all fields are returned)
46
+ # @option opts [Array<String>] :expand The list of fields that will be expanded in the response
47
+ # @option opts [String] :sync_token The sync token to select the only updated results
48
+ # @return [Array<(LocationResult, Integer, Hash)>] LocationResult data, response status code and response headers
49
+ def hris_locations_get_with_http_info(id, x_account_id, opts = {})
50
+ if @api_client.config.debugging
51
+ @api_client.config.logger.debug 'Calling API: LocationsApi.hris_locations_get ...'
52
+ end
53
+ # verify the required parameter 'id' is set
54
+ if @api_client.config.client_side_validation && id.nil?
55
+ fail ArgumentError, "Missing the required parameter 'id' when calling LocationsApi.hris_locations_get"
56
+ end
57
+ # verify the required parameter 'x_account_id' is set
58
+ if @api_client.config.client_side_validation && x_account_id.nil?
59
+ fail ArgumentError, "Missing the required parameter 'x_account_id' when calling LocationsApi.hris_locations_get"
60
+ end
61
+ # resource path
62
+ local_var_path = '/unified/hris/locations/{id}'.sub('{' + 'id' + '}', CGI.escape(id.to_s))
63
+
64
+ # query parameters
65
+ query_params = opts[:query_params] || {}
66
+ query_params[:'page'] = opts[:'page'] if !opts[:'page'].nil?
67
+ query_params[:'page_size'] = opts[:'page_size'] if !opts[:'page_size'].nil?
68
+ query_params[:'raw'] = opts[:'raw'] if !opts[:'raw'].nil?
69
+ query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :multi) if !opts[:'fields'].nil?
70
+ query_params[:'expand'] = @api_client.build_collection_param(opts[:'expand'], :multi) if !opts[:'expand'].nil?
71
+ query_params[:'sync_token'] = opts[:'sync_token'] if !opts[:'sync_token'].nil?
72
+
73
+ # header parameters
74
+ header_params = opts[:header_params] || {}
75
+ # HTTP header 'Accept' (if needed)
76
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
77
+ header_params[:'x-account-id'] = x_account_id
78
+
79
+ # form parameters
80
+ form_params = opts[:form_params] || {}
81
+
82
+ # http body (model)
83
+ post_body = opts[:debug_body]
84
+
85
+ # return_type
86
+ return_type = opts[:debug_return_type] || 'LocationResult'
87
+
88
+ # auth_names
89
+ auth_names = opts[:debug_auth_names] || ['basic']
90
+
91
+ new_options = opts.merge(
92
+ :operation => :"LocationsApi.hris_locations_get",
93
+ :header_params => header_params,
94
+ :query_params => query_params,
95
+ :form_params => form_params,
96
+ :body => post_body,
97
+ :auth_names => auth_names,
98
+ :return_type => return_type
99
+ )
100
+
101
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
102
+ if @api_client.config.debugging
103
+ @api_client.config.logger.debug "API called: LocationsApi#hris_locations_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
104
+ end
105
+ return data, status_code, headers
106
+ end
107
+
108
+ #
109
+ # @param x_account_id [String] The account identifier
110
+ # @param [Hash] opts the optional parameters
111
+ # @option opts [String] :page The page number of the results to fetch
112
+ # @option opts [String] :page_size The number of results per page (default to '25')
113
+ # @option opts [Boolean] :raw Indicates that the raw request result is returned (default to false)
114
+ # @option opts [Array<String>] :fields The list of fields to return in the response (if empty, all fields are returned)
115
+ # @option opts [Array<String>] :expand The list of fields that will be expanded in the response
116
+ # @option opts [String] :sync_token The sync token to select the only updated results
117
+ # @return [LocationsPaginated]
118
+ def hris_locations_list(x_account_id, opts = {})
119
+ data, _status_code, _headers = hris_locations_list_with_http_info(x_account_id, opts)
120
+ data
121
+ end
122
+
123
+ #
124
+ # @param x_account_id [String] The account identifier
125
+ # @param [Hash] opts the optional parameters
126
+ # @option opts [String] :page The page number of the results to fetch
127
+ # @option opts [String] :page_size The number of results per page (default to '25')
128
+ # @option opts [Boolean] :raw Indicates that the raw request result is returned (default to false)
129
+ # @option opts [Array<String>] :fields The list of fields to return in the response (if empty, all fields are returned)
130
+ # @option opts [Array<String>] :expand The list of fields that will be expanded in the response
131
+ # @option opts [String] :sync_token The sync token to select the only updated results
132
+ # @return [Array<(LocationsPaginated, Integer, Hash)>] LocationsPaginated data, response status code and response headers
133
+ def hris_locations_list_with_http_info(x_account_id, opts = {})
134
+ if @api_client.config.debugging
135
+ @api_client.config.logger.debug 'Calling API: LocationsApi.hris_locations_list ...'
136
+ end
137
+ # verify the required parameter 'x_account_id' is set
138
+ if @api_client.config.client_side_validation && x_account_id.nil?
139
+ fail ArgumentError, "Missing the required parameter 'x_account_id' when calling LocationsApi.hris_locations_list"
140
+ end
141
+ # resource path
142
+ local_var_path = '/unified/hris/locations'
143
+
144
+ # query parameters
145
+ query_params = opts[:query_params] || {}
146
+ query_params[:'page'] = opts[:'page'] if !opts[:'page'].nil?
147
+ query_params[:'page_size'] = opts[:'page_size'] if !opts[:'page_size'].nil?
148
+ query_params[:'raw'] = opts[:'raw'] if !opts[:'raw'].nil?
149
+ query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :multi) if !opts[:'fields'].nil?
150
+ query_params[:'expand'] = @api_client.build_collection_param(opts[:'expand'], :multi) if !opts[:'expand'].nil?
151
+ query_params[:'sync_token'] = opts[:'sync_token'] if !opts[:'sync_token'].nil?
152
+
153
+ # header parameters
154
+ header_params = opts[:header_params] || {}
155
+ # HTTP header 'Accept' (if needed)
156
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
157
+ header_params[:'x-account-id'] = x_account_id
158
+
159
+ # form parameters
160
+ form_params = opts[:form_params] || {}
161
+
162
+ # http body (model)
163
+ post_body = opts[:debug_body]
164
+
165
+ # return_type
166
+ return_type = opts[:debug_return_type] || 'LocationsPaginated'
167
+
168
+ # auth_names
169
+ auth_names = opts[:debug_auth_names] || ['basic']
170
+
171
+ new_options = opts.merge(
172
+ :operation => :"LocationsApi.hris_locations_list",
173
+ :header_params => header_params,
174
+ :query_params => query_params,
175
+ :form_params => form_params,
176
+ :body => post_body,
177
+ :auth_names => auth_names,
178
+ :return_type => return_type
179
+ )
180
+
181
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
182
+ if @api_client.config.debugging
183
+ @api_client.config.logger.debug "API called: LocationsApi#hris_locations_list\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
184
+ end
185
+ return data, status_code, headers
186
+ end
187
+ end
188
+ end
@@ -1,9 +1,9 @@
1
1
  =begin
2
- #StackOne Unified API
2
+ #StackOne Unified API - HRIS
3
3
 
4
- #The documentation for the StackOne Unified API
4
+ #The documentation for the StackOne Unified API - HRIS
5
5
 
6
- The version of the OpenAPI document: 1.0
6
+ The version of the OpenAPI document: 1.0.0
7
7
 
8
8
  Generated by: https://openapi-generator.tech
9
9
  OpenAPI Generator version: 6.4.0
@@ -17,7 +17,7 @@ require 'tempfile'
17
17
  require 'time'
18
18
  require 'typhoeus'
19
19
 
20
- module StackOneHrisClient
20
+ module StackOneHRIS
21
21
  class ApiClient
22
22
  # The Configuration object holding settings to be used in the API client.
23
23
  attr_accessor :config
@@ -278,7 +278,7 @@ module StackOneHrisClient
278
278
  end
279
279
  else
280
280
  # models (e.g. Pet) or oneOf
281
- klass = StackOneHrisClient.const_get(return_type)
281
+ klass = StackOneHRIS.const_get(return_type)
282
282
  klass.respond_to?(:openapi_one_of) ? klass.build(data) : klass.build_from_hash(data)
283
283
  end
284
284
  end
@@ -1,16 +1,16 @@
1
1
  =begin
2
- #StackOne Unified API
2
+ #StackOne Unified API - HRIS
3
3
 
4
- #The documentation for the StackOne Unified API
4
+ #The documentation for the StackOne Unified API - HRIS
5
5
 
6
- The version of the OpenAPI document: 1.0
6
+ The version of the OpenAPI document: 1.0.0
7
7
 
8
8
  Generated by: https://openapi-generator.tech
9
9
  OpenAPI Generator version: 6.4.0
10
10
 
11
11
  =end
12
12
 
13
- module StackOneHrisClient
13
+ module StackOneHRIS
14
14
  class ApiError < StandardError
15
15
  attr_reader :code, :response_headers, :response_body
16
16