authress-sdk 0.1.20.0 → 1.0.21.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +36 -32
- data/lib/authress_sdk.rb +18 -0
- data/lib/{swagger_client → authress_sdk}/api/access_records_api.rb +73 -80
- data/lib/{swagger_client → authress_sdk}/api/accounts_api.rb +31 -38
- data/lib/{swagger_client → authress_sdk}/api/metadata_api.rb +23 -30
- data/lib/{swagger_client → authress_sdk}/api/resource_permissions_api.rb +33 -40
- data/lib/{swagger_client → authress_sdk}/api/roles_api.rb +36 -43
- data/lib/{swagger_client → authress_sdk}/api/service_clients_api.rb +56 -63
- data/lib/{swagger_client → authress_sdk}/api/user_permissions_api.rb +44 -51
- data/lib/authress_sdk/api_error.rb +50 -0
- data/lib/{swagger_client/api_client.rb → authress_sdk/authress_client.rb} +36 -110
- data/lib/authress_sdk/constant_token_provider.rb +19 -0
- data/lib/{swagger_client → authress_sdk}/models/access_record.rb +4 -11
- data/lib/{swagger_client → authress_sdk}/models/access_record_collection.rb +4 -11
- data/lib/{swagger_client → authress_sdk}/models/access_record_collection_records.rb +4 -11
- data/lib/{swagger_client → authress_sdk}/models/account.rb +4 -11
- data/lib/{swagger_client/models/inline_response_200_11.rb → authress_sdk/models/account_collection.rb} +5 -12
- data/lib/{swagger_client → authress_sdk}/models/account_collection_accounts.rb +4 -11
- data/lib/{swagger_client → authress_sdk}/models/body.rb +4 -11
- data/lib/{swagger_client → authress_sdk}/models/body_1.rb +4 -11
- data/lib/{swagger_client → authress_sdk}/models/body_10.rb +4 -11
- data/lib/{swagger_client → authress_sdk}/models/body_11.rb +4 -11
- data/lib/{swagger_client → authress_sdk}/models/body_2.rb +4 -11
- data/lib/{swagger_client → authress_sdk}/models/body_3.rb +4 -11
- data/lib/{swagger_client → authress_sdk}/models/body_4.rb +4 -11
- data/lib/{swagger_client → authress_sdk}/models/body_5.rb +4 -11
- data/lib/{swagger_client → authress_sdk}/models/body_6.rb +4 -11
- data/lib/{swagger_client → authress_sdk}/models/body_7.rb +4 -11
- data/lib/{swagger_client → authress_sdk}/models/body_8.rb +4 -11
- data/lib/{swagger_client → authress_sdk}/models/body_9.rb +4 -11
- data/lib/{swagger_client → authress_sdk}/models/claim_request.rb +4 -11
- data/lib/{swagger_client → authress_sdk}/models/claim_response.rb +4 -11
- data/lib/{swagger_client → authress_sdk}/models/client.rb +4 -11
- data/lib/{swagger_client → authress_sdk}/models/client_access_key.rb +4 -11
- data/lib/{swagger_client → authress_sdk}/models/client_collection.rb +4 -11
- data/lib/{swagger_client → authress_sdk}/models/client_collection_clients.rb +4 -11
- data/lib/{swagger_client → authress_sdk}/models/identity.rb +4 -11
- data/lib/{swagger_client → authress_sdk}/models/identity_collection.rb +4 -11
- data/lib/{swagger_client → authress_sdk}/models/identity_collection_identities.rb +4 -11
- data/lib/{swagger_client → authress_sdk}/models/identity_request.rb +4 -11
- data/lib/{swagger_client → authress_sdk}/models/inline_response_200.rb +4 -11
- data/lib/{swagger_client → authress_sdk}/models/inline_response_200_1.rb +4 -11
- data/lib/{swagger_client → authress_sdk}/models/inline_response_200_10.rb +4 -11
- data/lib/{swagger_client/models/account_collection.rb → authress_sdk/models/inline_response_200_11.rb} +5 -12
- data/lib/{swagger_client → authress_sdk}/models/inline_response_200_12.rb +4 -11
- data/lib/{swagger_client → authress_sdk}/models/inline_response_200_13.rb +4 -11
- data/lib/{swagger_client → authress_sdk}/models/inline_response_200_14.rb +4 -11
- data/lib/{swagger_client → authress_sdk}/models/inline_response_200_15.rb +4 -11
- data/lib/{swagger_client → authress_sdk}/models/inline_response_200_2.rb +4 -11
- data/lib/{swagger_client → authress_sdk}/models/inline_response_200_3.rb +4 -11
- data/lib/{swagger_client → authress_sdk}/models/inline_response_200_4.rb +4 -11
- data/lib/{swagger_client → authress_sdk}/models/inline_response_200_5.rb +4 -11
- data/lib/{swagger_client → authress_sdk}/models/inline_response_200_6.rb +4 -11
- data/lib/{swagger_client → authress_sdk}/models/inline_response_200_7.rb +4 -11
- data/lib/{swagger_client → authress_sdk}/models/inline_response_200_8.rb +4 -11
- data/lib/{swagger_client → authress_sdk}/models/inline_response_200_9.rb +4 -11
- data/lib/{swagger_client → authress_sdk}/models/invite.rb +4 -11
- data/lib/{swagger_client → authress_sdk}/models/link.rb +4 -11
- data/lib/{swagger_client → authress_sdk}/models/metadata_object.rb +4 -11
- data/lib/{swagger_client/models/v1roles_permissions.rb → authress_sdk/models/permission_object.rb} +5 -12
- data/lib/{swagger_client → authress_sdk}/models/permission_response.rb +4 -11
- data/lib/{swagger_client → authress_sdk}/models/resource_permission.rb +4 -11
- data/lib/{swagger_client → authress_sdk}/models/resource_permission_collection.rb +4 -11
- data/lib/{swagger_client → authress_sdk}/models/resource_permission_collection_links.rb +4 -11
- data/lib/{swagger_client → authress_sdk}/models/resource_permission_collection_links_next.rb +4 -11
- data/lib/{swagger_client → authress_sdk}/models/resource_permission_collection_resources.rb +4 -11
- data/lib/{swagger_client → authress_sdk}/models/resource_users_collection.rb +4 -11
- data/lib/{swagger_client → authress_sdk}/models/role.rb +4 -11
- data/lib/{swagger_client → authress_sdk}/models/statement.rb +4 -11
- data/lib/{swagger_client → authress_sdk}/models/token_request.rb +4 -11
- data/lib/{swagger_client → authress_sdk}/models/user.rb +4 -11
- data/lib/{swagger_client → authress_sdk}/models/user_resources.rb +4 -11
- data/lib/{swagger_client → authress_sdk}/models/user_resources_resources.rb +4 -11
- data/lib/{swagger_client → authress_sdk}/models/user_token.rb +4 -11
- data/lib/{swagger_client → authress_sdk}/models/user_token_links.rb +4 -11
- data/lib/{swagger_client → authress_sdk}/models/user_token_links_self.rb +4 -11
- data/lib/{swagger_client → authress_sdk}/models/v1clients_options.rb +4 -11
- data/lib/{swagger_client → authress_sdk}/models/v1records_account.rb +4 -11
- data/lib/{swagger_client → authress_sdk}/models/v1records_links.rb +4 -11
- data/lib/{swagger_client → authress_sdk}/models/v1records_links_self.rb +4 -11
- data/lib/{swagger_client → authress_sdk}/models/v1records_users.rb +4 -11
- data/lib/{swagger_client → authress_sdk}/models/v1resourcesresource_uri_permissions.rb +4 -11
- data/lib/{swagger_client/models/permission_object.rb → authress_sdk/models/v1roles_permissions.rb} +5 -12
- data/lib/{swagger_client → authress_sdk}/models/v1usersuser_idresourcesresource_urimetadata_account.rb +4 -11
- data/lib/{swagger_client → authress_sdk}/models/v1usersuser_idtokens_resources.rb +4 -11
- data/lib/{swagger_client → authress_sdk}/models/v1usersuser_idtokens_statements.rb +4 -11
- data/lib/authress_sdk/service_client_token_provider.rb +18 -0
- metadata +87 -87
- data/lib/swagger_client.rb +0 -30
- data/lib/swagger_client/api_error.rb +0 -57
- data/lib/swagger_client/configuration.rb +0 -205
- data/lib/swagger_client/version.rb +0 -14
@@ -1,20 +1,13 @@
|
|
1
1
|
=begin
|
2
|
-
#Authress
|
3
2
|
|
4
|
-
#<p> <h2>Authorization</h2> <p>Authorization for Authress is handled one of two different ways. Both mechanisms use oauth2 <i>Bearer</i> tokens.</p> <br> <h4>Identity Provider JWT</h4> <p>Hook up your preferred identity provider directly to Authress. Authress will verify JWTs sourced from that identify provider and allow direct integration with these APIs. Any OIDC JWT provider works, Google, Auth0, Okta, etc... With this mechanism your web app can make direct calls to the permissions API on behalf of your users. <br> <a href=\"https://authress.io/app/#/manage?focus=identity\">Link identity provider</a> </p> <br> <h4>Authress Clients</h4> <p>Regardless of using direct identity provider integration, with the API you can create Authress clients which can call any of the methods on the API. Your users won't be able to directly make API calls, all web app integrations must go through a service which stores the Authress private key. <br> <a href=\"https://authress.io/app/#/manage?focus=clients\">Create Authress service client</a> </p> <br> <h2>Usage</h2> <h4>Billable APIs</h4> <p>Most of the api available is completely free. Use it to populate your roles and configure your account. You'll only be charged for the ones marked as Billable.</p> <p><ul> <li><i class=\"far fa-fw fa-money-bill-alt text-primary\"></i> <span class=\"text-primary\">Billable</span> - <small>These APIs count as calls for your account and will be charged.</small></li> <li><i class=\"fas fa-fw fa-angle-double-right text-secondary\"></i> <span class=\"text-secondary\">Free</span> - <small>These are totally free.</small></li> <li><i class=\"fas fa-fw fa-balance-scale text-secondary\"></i> <span class=\"text-secondary\">Condition</span> - <small>Are conditionally free, see api methods for details.</small></li> </ul></p> <br> <h4>API Access</h4> <p>Access to the following APIs is based on Authress permissions, not the application permissions assigned in Authress to the application services. Each resource is tagged with the required permission <span class=\"badge badge-outline-secondary\">Action: Resource</span> </p>
|
5
|
-
|
6
|
-
OpenAPI spec version: v1
|
7
|
-
Contact: support@authress.io
|
8
|
-
Generated by: https://github.com/swagger-api/swagger-codegen.git
|
9
|
-
Swagger Codegen version: 3.0.23
|
10
3
|
=end
|
11
4
|
|
12
|
-
module
|
5
|
+
module AuthressSdk
|
13
6
|
class RolesApi
|
14
|
-
attr_accessor :
|
7
|
+
attr_accessor :authress_client
|
15
8
|
|
16
|
-
def initialize(
|
17
|
-
@
|
9
|
+
def initialize(authress_client = AuthressClient.default)
|
10
|
+
@authress_client = authress_client
|
18
11
|
end
|
19
12
|
# Create a role.
|
20
13
|
# Creates a role with permissions. <br><span class=\"badge badge-outline-secondary\">CREATE: Authress:Roles</span>
|
@@ -32,11 +25,11 @@ module SwaggerClient
|
|
32
25
|
# @param [Hash] opts the optional parameters
|
33
26
|
# @return [Array<(InlineResponse20010, Integer, Hash)>] InlineResponse20010 data, response status code and response headers
|
34
27
|
def create_role_with_http_info(body, opts = {})
|
35
|
-
if @
|
36
|
-
@
|
28
|
+
if @authress_client.config.debugging
|
29
|
+
@authress_client.config.logger.debug 'Calling API: RolesApi.create_role ...'
|
37
30
|
end
|
38
31
|
# verify the required parameter 'body' is set
|
39
|
-
if @
|
32
|
+
if @authress_client.config.client_side_validation && body.nil?
|
40
33
|
fail ArgumentError, "Missing the required parameter 'body' when calling RolesApi.create_role"
|
41
34
|
end
|
42
35
|
# resource path
|
@@ -48,20 +41,20 @@ module SwaggerClient
|
|
48
41
|
# header parameters
|
49
42
|
header_params = opts[:header_params] || {}
|
50
43
|
# HTTP header 'Accept' (if needed)
|
51
|
-
header_params['Accept'] = @
|
44
|
+
header_params['Accept'] = @authress_client.select_header_accept(['application/links+json'])
|
52
45
|
# HTTP header 'Content-Type'
|
53
|
-
header_params['Content-Type'] = @
|
46
|
+
header_params['Content-Type'] = @authress_client.select_header_content_type(['application/json'])
|
54
47
|
|
55
48
|
# form parameters
|
56
49
|
form_params = opts[:form_params] || {}
|
57
50
|
|
58
51
|
# http body (model)
|
59
|
-
post_body = opts[:body] || @
|
52
|
+
post_body = opts[:body] || @authress_client.object_to_http_body(body)
|
60
53
|
|
61
54
|
return_type = opts[:return_type] || 'InlineResponse20010'
|
62
55
|
|
63
56
|
auth_names = opts[:auth_names] || ['oauth2']
|
64
|
-
data, status_code, headers = @
|
57
|
+
data, status_code, headers = @authress_client.call_api(:POST, local_var_path,
|
65
58
|
:header_params => header_params,
|
66
59
|
:query_params => query_params,
|
67
60
|
:form_params => form_params,
|
@@ -69,8 +62,8 @@ module SwaggerClient
|
|
69
62
|
:auth_names => auth_names,
|
70
63
|
:return_type => return_type)
|
71
64
|
|
72
|
-
if @
|
73
|
-
@
|
65
|
+
if @authress_client.config.debugging
|
66
|
+
@authress_client.config.logger.debug "API called: RolesApi#create_role\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
74
67
|
end
|
75
68
|
return data, status_code, headers
|
76
69
|
end
|
@@ -90,11 +83,11 @@ module SwaggerClient
|
|
90
83
|
# @param [Hash] opts the optional parameters
|
91
84
|
# @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
|
92
85
|
def delete_role_with_http_info(role_id, opts = {})
|
93
|
-
if @
|
94
|
-
@
|
86
|
+
if @authress_client.config.debugging
|
87
|
+
@authress_client.config.logger.debug 'Calling API: RolesApi.delete_role ...'
|
95
88
|
end
|
96
89
|
# verify the required parameter 'role_id' is set
|
97
|
-
if @
|
90
|
+
if @authress_client.config.client_side_validation && role_id.nil?
|
98
91
|
fail ArgumentError, "Missing the required parameter 'role_id' when calling RolesApi.delete_role"
|
99
92
|
end
|
100
93
|
# resource path
|
@@ -115,7 +108,7 @@ module SwaggerClient
|
|
115
108
|
return_type = opts[:return_type]
|
116
109
|
|
117
110
|
auth_names = opts[:auth_names] || ['oauth2']
|
118
|
-
data, status_code, headers = @
|
111
|
+
data, status_code, headers = @authress_client.call_api(:DELETE, local_var_path,
|
119
112
|
:header_params => header_params,
|
120
113
|
:query_params => query_params,
|
121
114
|
:form_params => form_params,
|
@@ -123,8 +116,8 @@ module SwaggerClient
|
|
123
116
|
:auth_names => auth_names,
|
124
117
|
:return_type => return_type)
|
125
118
|
|
126
|
-
if @
|
127
|
-
@
|
119
|
+
if @authress_client.config.debugging
|
120
|
+
@authress_client.config.logger.debug "API called: RolesApi#delete_role\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
128
121
|
end
|
129
122
|
return data, status_code, headers
|
130
123
|
end
|
@@ -144,11 +137,11 @@ module SwaggerClient
|
|
144
137
|
# @param [Hash] opts the optional parameters
|
145
138
|
# @return [Array<(InlineResponse20010, Integer, Hash)>] InlineResponse20010 data, response status code and response headers
|
146
139
|
def get_role_with_http_info(role_id, opts = {})
|
147
|
-
if @
|
148
|
-
@
|
140
|
+
if @authress_client.config.debugging
|
141
|
+
@authress_client.config.logger.debug 'Calling API: RolesApi.get_role ...'
|
149
142
|
end
|
150
143
|
# verify the required parameter 'role_id' is set
|
151
|
-
if @
|
144
|
+
if @authress_client.config.client_side_validation && role_id.nil?
|
152
145
|
fail ArgumentError, "Missing the required parameter 'role_id' when calling RolesApi.get_role"
|
153
146
|
end
|
154
147
|
# resource path
|
@@ -160,7 +153,7 @@ module SwaggerClient
|
|
160
153
|
# header parameters
|
161
154
|
header_params = opts[:header_params] || {}
|
162
155
|
# HTTP header 'Accept' (if needed)
|
163
|
-
header_params['Accept'] = @
|
156
|
+
header_params['Accept'] = @authress_client.select_header_accept(['application/links+json'])
|
164
157
|
|
165
158
|
# form parameters
|
166
159
|
form_params = opts[:form_params] || {}
|
@@ -171,7 +164,7 @@ module SwaggerClient
|
|
171
164
|
return_type = opts[:return_type] || 'InlineResponse20010'
|
172
165
|
|
173
166
|
auth_names = opts[:auth_names] || ['oauth2']
|
174
|
-
data, status_code, headers = @
|
167
|
+
data, status_code, headers = @authress_client.call_api(:GET, local_var_path,
|
175
168
|
:header_params => header_params,
|
176
169
|
:query_params => query_params,
|
177
170
|
:form_params => form_params,
|
@@ -179,8 +172,8 @@ module SwaggerClient
|
|
179
172
|
:auth_names => auth_names,
|
180
173
|
:return_type => return_type)
|
181
174
|
|
182
|
-
if @
|
183
|
-
@
|
175
|
+
if @authress_client.config.debugging
|
176
|
+
@authress_client.config.logger.debug "API called: RolesApi#get_role\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
184
177
|
end
|
185
178
|
return data, status_code, headers
|
186
179
|
end
|
@@ -202,15 +195,15 @@ module SwaggerClient
|
|
202
195
|
# @param [Hash] opts the optional parameters
|
203
196
|
# @return [Array<(InlineResponse20010, Integer, Hash)>] InlineResponse20010 data, response status code and response headers
|
204
197
|
def update_role_with_http_info(body, role_id, opts = {})
|
205
|
-
if @
|
206
|
-
@
|
198
|
+
if @authress_client.config.debugging
|
199
|
+
@authress_client.config.logger.debug 'Calling API: RolesApi.update_role ...'
|
207
200
|
end
|
208
201
|
# verify the required parameter 'body' is set
|
209
|
-
if @
|
202
|
+
if @authress_client.config.client_side_validation && body.nil?
|
210
203
|
fail ArgumentError, "Missing the required parameter 'body' when calling RolesApi.update_role"
|
211
204
|
end
|
212
205
|
# verify the required parameter 'role_id' is set
|
213
|
-
if @
|
206
|
+
if @authress_client.config.client_side_validation && role_id.nil?
|
214
207
|
fail ArgumentError, "Missing the required parameter 'role_id' when calling RolesApi.update_role"
|
215
208
|
end
|
216
209
|
# resource path
|
@@ -222,20 +215,20 @@ module SwaggerClient
|
|
222
215
|
# header parameters
|
223
216
|
header_params = opts[:header_params] || {}
|
224
217
|
# HTTP header 'Accept' (if needed)
|
225
|
-
header_params['Accept'] = @
|
218
|
+
header_params['Accept'] = @authress_client.select_header_accept(['application/links+json'])
|
226
219
|
# HTTP header 'Content-Type'
|
227
|
-
header_params['Content-Type'] = @
|
220
|
+
header_params['Content-Type'] = @authress_client.select_header_content_type(['application/json'])
|
228
221
|
|
229
222
|
# form parameters
|
230
223
|
form_params = opts[:form_params] || {}
|
231
224
|
|
232
225
|
# http body (model)
|
233
|
-
post_body = opts[:body] || @
|
226
|
+
post_body = opts[:body] || @authress_client.object_to_http_body(body)
|
234
227
|
|
235
228
|
return_type = opts[:return_type] || 'InlineResponse20010'
|
236
229
|
|
237
230
|
auth_names = opts[:auth_names] || ['oauth2']
|
238
|
-
data, status_code, headers = @
|
231
|
+
data, status_code, headers = @authress_client.call_api(:PUT, local_var_path,
|
239
232
|
:header_params => header_params,
|
240
233
|
:query_params => query_params,
|
241
234
|
:form_params => form_params,
|
@@ -243,8 +236,8 @@ module SwaggerClient
|
|
243
236
|
:auth_names => auth_names,
|
244
237
|
:return_type => return_type)
|
245
238
|
|
246
|
-
if @
|
247
|
-
@
|
239
|
+
if @authress_client.config.debugging
|
240
|
+
@authress_client.config.logger.debug "API called: RolesApi#update_role\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
248
241
|
end
|
249
242
|
return data, status_code, headers
|
250
243
|
end
|
@@ -1,20 +1,13 @@
|
|
1
1
|
=begin
|
2
|
-
#Authress
|
3
2
|
|
4
|
-
#<p> <h2>Authorization</h2> <p>Authorization for Authress is handled one of two different ways. Both mechanisms use oauth2 <i>Bearer</i> tokens.</p> <br> <h4>Identity Provider JWT</h4> <p>Hook up your preferred identity provider directly to Authress. Authress will verify JWTs sourced from that identify provider and allow direct integration with these APIs. Any OIDC JWT provider works, Google, Auth0, Okta, etc... With this mechanism your web app can make direct calls to the permissions API on behalf of your users. <br> <a href=\"https://authress.io/app/#/manage?focus=identity\">Link identity provider</a> </p> <br> <h4>Authress Clients</h4> <p>Regardless of using direct identity provider integration, with the API you can create Authress clients which can call any of the methods on the API. Your users won't be able to directly make API calls, all web app integrations must go through a service which stores the Authress private key. <br> <a href=\"https://authress.io/app/#/manage?focus=clients\">Create Authress service client</a> </p> <br> <h2>Usage</h2> <h4>Billable APIs</h4> <p>Most of the api available is completely free. Use it to populate your roles and configure your account. You'll only be charged for the ones marked as Billable.</p> <p><ul> <li><i class=\"far fa-fw fa-money-bill-alt text-primary\"></i> <span class=\"text-primary\">Billable</span> - <small>These APIs count as calls for your account and will be charged.</small></li> <li><i class=\"fas fa-fw fa-angle-double-right text-secondary\"></i> <span class=\"text-secondary\">Free</span> - <small>These are totally free.</small></li> <li><i class=\"fas fa-fw fa-balance-scale text-secondary\"></i> <span class=\"text-secondary\">Condition</span> - <small>Are conditionally free, see api methods for details.</small></li> </ul></p> <br> <h4>API Access</h4> <p>Access to the following APIs is based on Authress permissions, not the application permissions assigned in Authress to the application services. Each resource is tagged with the required permission <span class=\"badge badge-outline-secondary\">Action: Resource</span> </p>
|
5
|
-
|
6
|
-
OpenAPI spec version: v1
|
7
|
-
Contact: support@authress.io
|
8
|
-
Generated by: https://github.com/swagger-api/swagger-codegen.git
|
9
|
-
Swagger Codegen version: 3.0.23
|
10
3
|
=end
|
11
4
|
|
12
|
-
module
|
5
|
+
module AuthressSdk
|
13
6
|
class ServiceClientsApi
|
14
|
-
attr_accessor :
|
7
|
+
attr_accessor :authress_client
|
15
8
|
|
16
|
-
def initialize(
|
17
|
-
@
|
9
|
+
def initialize(authress_client = AuthressClient.default)
|
10
|
+
@authress_client = authress_client
|
18
11
|
end
|
19
12
|
# Create a new client.
|
20
13
|
# Creates a service client to interact with Authress or any other service on behalf of users. Each client has secret private keys used to authenticate with Authress. To use service clients created through other mechanisms, skip creating a client and create access records with the client identifier. <br><span class=\"badge badge-outline-secondary\">CREATE: Authress:ServiceClients</span> or <span class=\"badge badge-outline-secondary\">RESOURCE CLAIM: Authress:ServiceClients</span>
|
@@ -32,11 +25,11 @@ module SwaggerClient
|
|
32
25
|
# @param [Hash] opts the optional parameters
|
33
26
|
# @return [Array<(InlineResponse20014, Integer, Hash)>] InlineResponse20014 data, response status code and response headers
|
34
27
|
def create_client_with_http_info(body, opts = {})
|
35
|
-
if @
|
36
|
-
@
|
28
|
+
if @authress_client.config.debugging
|
29
|
+
@authress_client.config.logger.debug 'Calling API: ServiceClientsApi.create_client ...'
|
37
30
|
end
|
38
31
|
# verify the required parameter 'body' is set
|
39
|
-
if @
|
32
|
+
if @authress_client.config.client_side_validation && body.nil?
|
40
33
|
fail ArgumentError, "Missing the required parameter 'body' when calling ServiceClientsApi.create_client"
|
41
34
|
end
|
42
35
|
# resource path
|
@@ -48,20 +41,20 @@ module SwaggerClient
|
|
48
41
|
# header parameters
|
49
42
|
header_params = opts[:header_params] || {}
|
50
43
|
# HTTP header 'Accept' (if needed)
|
51
|
-
header_params['Accept'] = @
|
44
|
+
header_params['Accept'] = @authress_client.select_header_accept(['application/links+json'])
|
52
45
|
# HTTP header 'Content-Type'
|
53
|
-
header_params['Content-Type'] = @
|
46
|
+
header_params['Content-Type'] = @authress_client.select_header_content_type(['application/json'])
|
54
47
|
|
55
48
|
# form parameters
|
56
49
|
form_params = opts[:form_params] || {}
|
57
50
|
|
58
51
|
# http body (model)
|
59
|
-
post_body = opts[:body] || @
|
52
|
+
post_body = opts[:body] || @authress_client.object_to_http_body(body)
|
60
53
|
|
61
54
|
return_type = opts[:return_type] || 'InlineResponse20014'
|
62
55
|
|
63
56
|
auth_names = opts[:auth_names] || ['oauth2']
|
64
|
-
data, status_code, headers = @
|
57
|
+
data, status_code, headers = @authress_client.call_api(:POST, local_var_path,
|
65
58
|
:header_params => header_params,
|
66
59
|
:query_params => query_params,
|
67
60
|
:form_params => form_params,
|
@@ -69,8 +62,8 @@ module SwaggerClient
|
|
69
62
|
:auth_names => auth_names,
|
70
63
|
:return_type => return_type)
|
71
64
|
|
72
|
-
if @
|
73
|
-
@
|
65
|
+
if @authress_client.config.debugging
|
66
|
+
@authress_client.config.logger.debug "API called: ServiceClientsApi#create_client\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
74
67
|
end
|
75
68
|
return data, status_code, headers
|
76
69
|
end
|
@@ -92,15 +85,15 @@ module SwaggerClient
|
|
92
85
|
# @param [Hash] opts the optional parameters
|
93
86
|
# @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
|
94
87
|
def delete_access_key_with_http_info(client_id, key_id, opts = {})
|
95
|
-
if @
|
96
|
-
@
|
88
|
+
if @authress_client.config.debugging
|
89
|
+
@authress_client.config.logger.debug 'Calling API: ServiceClientsApi.delete_access_key ...'
|
97
90
|
end
|
98
91
|
# verify the required parameter 'client_id' is set
|
99
|
-
if @
|
92
|
+
if @authress_client.config.client_side_validation && client_id.nil?
|
100
93
|
fail ArgumentError, "Missing the required parameter 'client_id' when calling ServiceClientsApi.delete_access_key"
|
101
94
|
end
|
102
95
|
# verify the required parameter 'key_id' is set
|
103
|
-
if @
|
96
|
+
if @authress_client.config.client_side_validation && key_id.nil?
|
104
97
|
fail ArgumentError, "Missing the required parameter 'key_id' when calling ServiceClientsApi.delete_access_key"
|
105
98
|
end
|
106
99
|
# resource path
|
@@ -121,7 +114,7 @@ module SwaggerClient
|
|
121
114
|
return_type = opts[:return_type]
|
122
115
|
|
123
116
|
auth_names = opts[:auth_names] || ['oauth2']
|
124
|
-
data, status_code, headers = @
|
117
|
+
data, status_code, headers = @authress_client.call_api(:DELETE, local_var_path,
|
125
118
|
:header_params => header_params,
|
126
119
|
:query_params => query_params,
|
127
120
|
:form_params => form_params,
|
@@ -129,8 +122,8 @@ module SwaggerClient
|
|
129
122
|
:auth_names => auth_names,
|
130
123
|
:return_type => return_type)
|
131
124
|
|
132
|
-
if @
|
133
|
-
@
|
125
|
+
if @authress_client.config.debugging
|
126
|
+
@authress_client.config.logger.debug "API called: ServiceClientsApi#delete_access_key\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
134
127
|
end
|
135
128
|
return data, status_code, headers
|
136
129
|
end
|
@@ -150,11 +143,11 @@ module SwaggerClient
|
|
150
143
|
# @param [Hash] opts the optional parameters
|
151
144
|
# @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
|
152
145
|
def delete_client_with_http_info(client_id, opts = {})
|
153
|
-
if @
|
154
|
-
@
|
146
|
+
if @authress_client.config.debugging
|
147
|
+
@authress_client.config.logger.debug 'Calling API: ServiceClientsApi.delete_client ...'
|
155
148
|
end
|
156
149
|
# verify the required parameter 'client_id' is set
|
157
|
-
if @
|
150
|
+
if @authress_client.config.client_side_validation && client_id.nil?
|
158
151
|
fail ArgumentError, "Missing the required parameter 'client_id' when calling ServiceClientsApi.delete_client"
|
159
152
|
end
|
160
153
|
# resource path
|
@@ -175,7 +168,7 @@ module SwaggerClient
|
|
175
168
|
return_type = opts[:return_type]
|
176
169
|
|
177
170
|
auth_names = opts[:auth_names] || ['oauth2']
|
178
|
-
data, status_code, headers = @
|
171
|
+
data, status_code, headers = @authress_client.call_api(:DELETE, local_var_path,
|
179
172
|
:header_params => header_params,
|
180
173
|
:query_params => query_params,
|
181
174
|
:form_params => form_params,
|
@@ -183,8 +176,8 @@ module SwaggerClient
|
|
183
176
|
:auth_names => auth_names,
|
184
177
|
:return_type => return_type)
|
185
178
|
|
186
|
-
if @
|
187
|
-
@
|
179
|
+
if @authress_client.config.debugging
|
180
|
+
@authress_client.config.logger.debug "API called: ServiceClientsApi#delete_client\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
188
181
|
end
|
189
182
|
return data, status_code, headers
|
190
183
|
end
|
@@ -204,11 +197,11 @@ module SwaggerClient
|
|
204
197
|
# @param [Hash] opts the optional parameters
|
205
198
|
# @return [Array<(InlineResponse20014, Integer, Hash)>] InlineResponse20014 data, response status code and response headers
|
206
199
|
def get_client_with_http_info(client_id, opts = {})
|
207
|
-
if @
|
208
|
-
@
|
200
|
+
if @authress_client.config.debugging
|
201
|
+
@authress_client.config.logger.debug 'Calling API: ServiceClientsApi.get_client ...'
|
209
202
|
end
|
210
203
|
# verify the required parameter 'client_id' is set
|
211
|
-
if @
|
204
|
+
if @authress_client.config.client_side_validation && client_id.nil?
|
212
205
|
fail ArgumentError, "Missing the required parameter 'client_id' when calling ServiceClientsApi.get_client"
|
213
206
|
end
|
214
207
|
# resource path
|
@@ -220,7 +213,7 @@ module SwaggerClient
|
|
220
213
|
# header parameters
|
221
214
|
header_params = opts[:header_params] || {}
|
222
215
|
# HTTP header 'Accept' (if needed)
|
223
|
-
header_params['Accept'] = @
|
216
|
+
header_params['Accept'] = @authress_client.select_header_accept(['application/links+json'])
|
224
217
|
|
225
218
|
# form parameters
|
226
219
|
form_params = opts[:form_params] || {}
|
@@ -231,7 +224,7 @@ module SwaggerClient
|
|
231
224
|
return_type = opts[:return_type] || 'InlineResponse20014'
|
232
225
|
|
233
226
|
auth_names = opts[:auth_names] || ['oauth2']
|
234
|
-
data, status_code, headers = @
|
227
|
+
data, status_code, headers = @authress_client.call_api(:GET, local_var_path,
|
235
228
|
:header_params => header_params,
|
236
229
|
:query_params => query_params,
|
237
230
|
:form_params => form_params,
|
@@ -239,8 +232,8 @@ module SwaggerClient
|
|
239
232
|
:auth_names => auth_names,
|
240
233
|
:return_type => return_type)
|
241
234
|
|
242
|
-
if @
|
243
|
-
@
|
235
|
+
if @authress_client.config.debugging
|
236
|
+
@authress_client.config.logger.debug "API called: ServiceClientsApi#get_client\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
244
237
|
end
|
245
238
|
return data, status_code, headers
|
246
239
|
end
|
@@ -258,8 +251,8 @@ module SwaggerClient
|
|
258
251
|
# @param [Hash] opts the optional parameters
|
259
252
|
# @return [Array<(InlineResponse20013, Integer, Hash)>] InlineResponse20013 data, response status code and response headers
|
260
253
|
def get_clients_with_http_info(opts = {})
|
261
|
-
if @
|
262
|
-
@
|
254
|
+
if @authress_client.config.debugging
|
255
|
+
@authress_client.config.logger.debug 'Calling API: ServiceClientsApi.get_clients ...'
|
263
256
|
end
|
264
257
|
# resource path
|
265
258
|
local_var_path = '/v1/clients'
|
@@ -270,7 +263,7 @@ module SwaggerClient
|
|
270
263
|
# header parameters
|
271
264
|
header_params = opts[:header_params] || {}
|
272
265
|
# HTTP header 'Accept' (if needed)
|
273
|
-
header_params['Accept'] = @
|
266
|
+
header_params['Accept'] = @authress_client.select_header_accept(['application/links+json'])
|
274
267
|
|
275
268
|
# form parameters
|
276
269
|
form_params = opts[:form_params] || {}
|
@@ -281,7 +274,7 @@ module SwaggerClient
|
|
281
274
|
return_type = opts[:return_type] || 'InlineResponse20013'
|
282
275
|
|
283
276
|
auth_names = opts[:auth_names] || ['oauth2']
|
284
|
-
data, status_code, headers = @
|
277
|
+
data, status_code, headers = @authress_client.call_api(:GET, local_var_path,
|
285
278
|
:header_params => header_params,
|
286
279
|
:query_params => query_params,
|
287
280
|
:form_params => form_params,
|
@@ -289,8 +282,8 @@ module SwaggerClient
|
|
289
282
|
:auth_names => auth_names,
|
290
283
|
:return_type => return_type)
|
291
284
|
|
292
|
-
if @
|
293
|
-
@
|
285
|
+
if @authress_client.config.debugging
|
286
|
+
@authress_client.config.logger.debug "API called: ServiceClientsApi#get_clients\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
294
287
|
end
|
295
288
|
return data, status_code, headers
|
296
289
|
end
|
@@ -310,11 +303,11 @@ module SwaggerClient
|
|
310
303
|
# @param [Hash] opts the optional parameters
|
311
304
|
# @return [Array<(InlineResponse20015, Integer, Hash)>] InlineResponse20015 data, response status code and response headers
|
312
305
|
def request_access_key_with_http_info(client_id, opts = {})
|
313
|
-
if @
|
314
|
-
@
|
306
|
+
if @authress_client.config.debugging
|
307
|
+
@authress_client.config.logger.debug 'Calling API: ServiceClientsApi.request_access_key ...'
|
315
308
|
end
|
316
309
|
# verify the required parameter 'client_id' is set
|
317
|
-
if @
|
310
|
+
if @authress_client.config.client_side_validation && client_id.nil?
|
318
311
|
fail ArgumentError, "Missing the required parameter 'client_id' when calling ServiceClientsApi.request_access_key"
|
319
312
|
end
|
320
313
|
# resource path
|
@@ -326,7 +319,7 @@ module SwaggerClient
|
|
326
319
|
# header parameters
|
327
320
|
header_params = opts[:header_params] || {}
|
328
321
|
# HTTP header 'Accept' (if needed)
|
329
|
-
header_params['Accept'] = @
|
322
|
+
header_params['Accept'] = @authress_client.select_header_accept(['application/links+json'])
|
330
323
|
|
331
324
|
# form parameters
|
332
325
|
form_params = opts[:form_params] || {}
|
@@ -337,7 +330,7 @@ module SwaggerClient
|
|
337
330
|
return_type = opts[:return_type] || 'InlineResponse20015'
|
338
331
|
|
339
332
|
auth_names = opts[:auth_names] || ['oauth2']
|
340
|
-
data, status_code, headers = @
|
333
|
+
data, status_code, headers = @authress_client.call_api(:POST, local_var_path,
|
341
334
|
:header_params => header_params,
|
342
335
|
:query_params => query_params,
|
343
336
|
:form_params => form_params,
|
@@ -345,8 +338,8 @@ module SwaggerClient
|
|
345
338
|
:auth_names => auth_names,
|
346
339
|
:return_type => return_type)
|
347
340
|
|
348
|
-
if @
|
349
|
-
@
|
341
|
+
if @authress_client.config.debugging
|
342
|
+
@authress_client.config.logger.debug "API called: ServiceClientsApi#request_access_key\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
350
343
|
end
|
351
344
|
return data, status_code, headers
|
352
345
|
end
|
@@ -368,15 +361,15 @@ module SwaggerClient
|
|
368
361
|
# @param [Hash] opts the optional parameters
|
369
362
|
# @return [Array<(InlineResponse20014, Integer, Hash)>] InlineResponse20014 data, response status code and response headers
|
370
363
|
def update_client_with_http_info(body, client_id, opts = {})
|
371
|
-
if @
|
372
|
-
@
|
364
|
+
if @authress_client.config.debugging
|
365
|
+
@authress_client.config.logger.debug 'Calling API: ServiceClientsApi.update_client ...'
|
373
366
|
end
|
374
367
|
# verify the required parameter 'body' is set
|
375
|
-
if @
|
368
|
+
if @authress_client.config.client_side_validation && body.nil?
|
376
369
|
fail ArgumentError, "Missing the required parameter 'body' when calling ServiceClientsApi.update_client"
|
377
370
|
end
|
378
371
|
# verify the required parameter 'client_id' is set
|
379
|
-
if @
|
372
|
+
if @authress_client.config.client_side_validation && client_id.nil?
|
380
373
|
fail ArgumentError, "Missing the required parameter 'client_id' when calling ServiceClientsApi.update_client"
|
381
374
|
end
|
382
375
|
# resource path
|
@@ -388,20 +381,20 @@ module SwaggerClient
|
|
388
381
|
# header parameters
|
389
382
|
header_params = opts[:header_params] || {}
|
390
383
|
# HTTP header 'Accept' (if needed)
|
391
|
-
header_params['Accept'] = @
|
384
|
+
header_params['Accept'] = @authress_client.select_header_accept(['application/links+json'])
|
392
385
|
# HTTP header 'Content-Type'
|
393
|
-
header_params['Content-Type'] = @
|
386
|
+
header_params['Content-Type'] = @authress_client.select_header_content_type(['application/json'])
|
394
387
|
|
395
388
|
# form parameters
|
396
389
|
form_params = opts[:form_params] || {}
|
397
390
|
|
398
391
|
# http body (model)
|
399
|
-
post_body = opts[:body] || @
|
392
|
+
post_body = opts[:body] || @authress_client.object_to_http_body(body)
|
400
393
|
|
401
394
|
return_type = opts[:return_type] || 'InlineResponse20014'
|
402
395
|
|
403
396
|
auth_names = opts[:auth_names] || ['oauth2']
|
404
|
-
data, status_code, headers = @
|
397
|
+
data, status_code, headers = @authress_client.call_api(:PUT, local_var_path,
|
405
398
|
:header_params => header_params,
|
406
399
|
:query_params => query_params,
|
407
400
|
:form_params => form_params,
|
@@ -409,8 +402,8 @@ module SwaggerClient
|
|
409
402
|
:auth_names => auth_names,
|
410
403
|
:return_type => return_type)
|
411
404
|
|
412
|
-
if @
|
413
|
-
@
|
405
|
+
if @authress_client.config.debugging
|
406
|
+
@authress_client.config.logger.debug "API called: ServiceClientsApi#update_client\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
414
407
|
end
|
415
408
|
return data, status_code, headers
|
416
409
|
end
|