pulp_npm_client 0.5.0 → 0.7.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/README.md +13 -9
- data/docs/ContentPackagesApi.md +115 -22
- data/docs/DistributionsNpmApi.md +4 -4
- data/docs/NpmNpmRemote.md +6 -6
- data/docs/NpmNpmRemoteResponse.md +9 -9
- data/docs/NpmPackageResponse.md +3 -3
- data/docs/PatchednpmNpmRemote.md +6 -6
- data/docs/RemoteNetworkConfig.md +50 -0
- data/docs/RemoteNetworkConfigResponse.md +40 -0
- data/docs/RemotesNpmApi.md +3 -3
- data/docs/RepositoriesNpmApi.md +5 -5
- data/lib/pulp_npm_client/api/content_packages_api.rb +146 -47
- data/lib/pulp_npm_client/api/distributions_npm_api.rb +4 -4
- data/lib/pulp_npm_client/api/remotes_npm_api.rb +6 -6
- data/lib/pulp_npm_client/api/repositories_npm_api.rb +8 -8
- data/lib/pulp_npm_client/models/npm_npm_remote.rb +34 -34
- data/lib/pulp_npm_client/models/npm_npm_remote_response.rb +50 -50
- data/lib/pulp_npm_client/models/npm_npm_repository.rb +1 -1
- data/lib/pulp_npm_client/models/npm_npm_repository_response.rb +1 -1
- data/lib/pulp_npm_client/models/npm_package_response.rb +4 -22
- data/lib/pulp_npm_client/models/patchednpm_npm_remote.rb +34 -34
- data/lib/pulp_npm_client/models/patchednpm_npm_repository.rb +1 -1
- data/lib/pulp_npm_client/models/remote_network_config.rb +573 -0
- data/lib/pulp_npm_client/models/remote_network_config_response.rb +398 -0
- data/lib/pulp_npm_client/version.rb +1 -1
- data/lib/pulp_npm_client.rb +2 -0
- data/spec/api/content_packages_api_spec.rb +32 -10
- data/spec/api/distributions_npm_api_spec.rb +2 -2
- data/spec/api/remotes_npm_api_spec.rb +3 -3
- data/spec/api/repositories_npm_api_spec.rb +4 -4
- data/spec/models/npm_npm_remote_response_spec.rb +10 -10
- data/spec/models/npm_npm_remote_spec.rb +17 -17
- data/spec/models/patchednpm_npm_remote_spec.rb +17 -17
- data/spec/models/remote_network_config_response_spec.rb +102 -0
- data/spec/models/remote_network_config_spec.rb +132 -0
- metadata +30 -22
data/docs/RepositoriesNpmApi.md
CHANGED
|
@@ -22,7 +22,7 @@ All URIs are relative to *http://localhost:24817*
|
|
|
22
22
|
|
|
23
23
|
Create a npm repository
|
|
24
24
|
|
|
25
|
-
A ViewSet for NpmRepository. Similar to the
|
|
25
|
+
A ViewSet for NpmRepository. Similar to the NpmPackageViewSet above, define endpoint_name, queryset and serializer, at a minimum.
|
|
26
26
|
|
|
27
27
|
### Examples
|
|
28
28
|
|
|
@@ -170,7 +170,7 @@ end
|
|
|
170
170
|
|
|
171
171
|
List npm repositorys
|
|
172
172
|
|
|
173
|
-
A ViewSet for NpmRepository. Similar to the
|
|
173
|
+
A ViewSet for NpmRepository. Similar to the NpmPackageViewSet above, define endpoint_name, queryset and serializer, at a minimum.
|
|
174
174
|
|
|
175
175
|
### Examples
|
|
176
176
|
|
|
@@ -205,7 +205,7 @@ opts = {
|
|
|
205
205
|
pulp_id__in: ['inner_example'], # Array<String> | Multiple values may be separated by commas.
|
|
206
206
|
pulp_label_select: 'pulp_label_select_example', # String | Filter labels by search string
|
|
207
207
|
q: 'q_example', # String | Filter results by using NOT, AND and OR operations on other filters
|
|
208
|
-
remote: '
|
|
208
|
+
remote: 'remote_example', # String |
|
|
209
209
|
retain_repo_versions: 56, # Integer | Filter results where retain_repo_versions matches value
|
|
210
210
|
retain_repo_versions__gt: 56, # Integer | Filter results where retain_repo_versions is greater than value
|
|
211
211
|
retain_repo_versions__gte: 56, # Integer | Filter results where retain_repo_versions is greater than or equal to value
|
|
@@ -269,7 +269,7 @@ end
|
|
|
269
269
|
| **pulp_id__in** | [**Array<String>**](String.md) | Multiple values may be separated by commas. | [optional] |
|
|
270
270
|
| **pulp_label_select** | **String** | Filter labels by search string | [optional] |
|
|
271
271
|
| **q** | **String** | Filter results by using NOT, AND and OR operations on other filters | [optional] |
|
|
272
|
-
| **remote** | **String** |
|
|
272
|
+
| **remote** | **String** | | [optional] |
|
|
273
273
|
| **retain_repo_versions** | **Integer** | Filter results where retain_repo_versions matches value | [optional] |
|
|
274
274
|
| **retain_repo_versions__gt** | **Integer** | Filter results where retain_repo_versions is greater than value | [optional] |
|
|
275
275
|
| **retain_repo_versions__gte** | **Integer** | Filter results where retain_repo_versions is greater than or equal to value | [optional] |
|
|
@@ -454,7 +454,7 @@ end
|
|
|
454
454
|
|
|
455
455
|
Inspect a npm repository
|
|
456
456
|
|
|
457
|
-
A ViewSet for NpmRepository. Similar to the
|
|
457
|
+
A ViewSet for NpmRepository. Similar to the NpmPackageViewSet above, define endpoint_name, queryset and serializer, at a minimum.
|
|
458
458
|
|
|
459
459
|
### Examples
|
|
460
460
|
|
|
@@ -20,68 +20,58 @@ module PulpNpmClient
|
|
|
20
20
|
@api_client = api_client
|
|
21
21
|
end
|
|
22
22
|
# Create a package
|
|
23
|
-
#
|
|
24
|
-
# @param relative_path [String]
|
|
25
|
-
# @param name [String]
|
|
26
|
-
# @param version [String]
|
|
23
|
+
# Trigger an asynchronous task to create content,optionally create new repository version.
|
|
27
24
|
# @param [Hash] opts the optional parameters
|
|
28
25
|
# @option opts [Array<String>] :x_task_diagnostics List of profilers to use on tasks.
|
|
29
26
|
# @option opts [String] :repository A URI of a repository the new content unit should be associated with.
|
|
30
27
|
# @option opts [Hash<String, String>] :pulp_labels A dictionary of arbitrary key/value pairs used to describe a specific Content instance.
|
|
31
28
|
# @option opts [String] :artifact Artifact file representing the physical content
|
|
29
|
+
# @option opts [String] :relative_path Path where the artifact is located relative to distributions base_path. If not provided, it will be computed from name and version.
|
|
32
30
|
# @option opts [File] :file An uploaded file that may be turned into the content unit.
|
|
33
31
|
# @option opts [String] :upload An uncommitted upload that may be turned into the content unit.
|
|
34
32
|
# @option opts [String] :file_url A url that Pulp can download and turn into the content unit.
|
|
35
|
-
# @
|
|
36
|
-
|
|
37
|
-
|
|
33
|
+
# @option opts [RemoteNetworkConfig] :downloader_config Configuration for the download process (e.g., proxies, auth, timeouts). Only applicable when providing a 'file_url.
|
|
34
|
+
# @option opts [String] :name The name of the npm package.
|
|
35
|
+
# @option opts [String] :version The version of the npm package.
|
|
36
|
+
# @return [AsyncOperationResponse]
|
|
37
|
+
def create(opts = {})
|
|
38
|
+
data, _status_code, _headers = create_with_http_info(opts)
|
|
38
39
|
data
|
|
39
40
|
end
|
|
40
41
|
|
|
41
42
|
# Create a package
|
|
42
|
-
#
|
|
43
|
-
# @param relative_path [String]
|
|
44
|
-
# @param name [String]
|
|
45
|
-
# @param version [String]
|
|
43
|
+
# Trigger an asynchronous task to create content,optionally create new repository version.
|
|
46
44
|
# @param [Hash] opts the optional parameters
|
|
47
45
|
# @option opts [Array<String>] :x_task_diagnostics List of profilers to use on tasks.
|
|
48
46
|
# @option opts [String] :repository A URI of a repository the new content unit should be associated with.
|
|
49
47
|
# @option opts [Hash<String, String>] :pulp_labels A dictionary of arbitrary key/value pairs used to describe a specific Content instance.
|
|
50
48
|
# @option opts [String] :artifact Artifact file representing the physical content
|
|
49
|
+
# @option opts [String] :relative_path Path where the artifact is located relative to distributions base_path. If not provided, it will be computed from name and version.
|
|
51
50
|
# @option opts [File] :file An uploaded file that may be turned into the content unit.
|
|
52
51
|
# @option opts [String] :upload An uncommitted upload that may be turned into the content unit.
|
|
53
52
|
# @option opts [String] :file_url A url that Pulp can download and turn into the content unit.
|
|
54
|
-
# @
|
|
55
|
-
|
|
53
|
+
# @option opts [RemoteNetworkConfig] :downloader_config Configuration for the download process (e.g., proxies, auth, timeouts). Only applicable when providing a 'file_url.
|
|
54
|
+
# @option opts [String] :name The name of the npm package.
|
|
55
|
+
# @option opts [String] :version The version of the npm package.
|
|
56
|
+
# @return [Array<(AsyncOperationResponse, Integer, Hash)>] AsyncOperationResponse data, response status code and response headers
|
|
57
|
+
def create_with_http_info(opts = {})
|
|
56
58
|
if @api_client.config.debugging
|
|
57
59
|
@api_client.config.logger.debug 'Calling API: ContentPackagesApi.create ...'
|
|
58
60
|
end
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
fail ArgumentError, "Missing the required parameter 'relative_path' when calling ContentPackagesApi.create"
|
|
62
|
-
end
|
|
63
|
-
if @api_client.config.client_side_validation && relative_path.to_s.length < 1
|
|
64
|
-
fail ArgumentError, 'invalid value for "relative_path" when calling ContentPackagesApi.create, the character length must be great than or equal to 1.'
|
|
61
|
+
if @api_client.config.client_side_validation && !opts[:'relative_path'].nil? && opts[:'relative_path'].to_s.length < 1
|
|
62
|
+
fail ArgumentError, 'invalid value for "opts[:"relative_path"]" when calling ContentPackagesApi.create, the character length must be great than or equal to 1.'
|
|
65
63
|
end
|
|
66
64
|
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
fail ArgumentError, "Missing the required parameter 'name' when calling ContentPackagesApi.create"
|
|
70
|
-
end
|
|
71
|
-
if @api_client.config.client_side_validation && name.to_s.length < 1
|
|
72
|
-
fail ArgumentError, 'invalid value for "name" when calling ContentPackagesApi.create, the character length must be great than or equal to 1.'
|
|
65
|
+
if @api_client.config.client_side_validation && !opts[:'file_url'].nil? && opts[:'file_url'].to_s.length < 1
|
|
66
|
+
fail ArgumentError, 'invalid value for "opts[:"file_url"]" when calling ContentPackagesApi.create, the character length must be great than or equal to 1.'
|
|
73
67
|
end
|
|
74
68
|
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
fail ArgumentError, "Missing the required parameter 'version' when calling ContentPackagesApi.create"
|
|
78
|
-
end
|
|
79
|
-
if @api_client.config.client_side_validation && version.to_s.length < 1
|
|
80
|
-
fail ArgumentError, 'invalid value for "version" when calling ContentPackagesApi.create, the character length must be great than or equal to 1.'
|
|
69
|
+
if @api_client.config.client_side_validation && !opts[:'name'].nil? && opts[:'name'].to_s.length < 1
|
|
70
|
+
fail ArgumentError, 'invalid value for "opts[:"name"]" when calling ContentPackagesApi.create, the character length must be great than or equal to 1.'
|
|
81
71
|
end
|
|
82
72
|
|
|
83
|
-
if @api_client.config.client_side_validation && !opts[:'
|
|
84
|
-
fail ArgumentError, 'invalid value for "opts[:"
|
|
73
|
+
if @api_client.config.client_side_validation && !opts[:'version'].nil? && opts[:'version'].to_s.length < 1
|
|
74
|
+
fail ArgumentError, 'invalid value for "opts[:"version"]" when calling ContentPackagesApi.create, the character length must be great than or equal to 1.'
|
|
85
75
|
end
|
|
86
76
|
|
|
87
77
|
# resource path
|
|
@@ -103,21 +93,22 @@ module PulpNpmClient
|
|
|
103
93
|
|
|
104
94
|
# form parameters
|
|
105
95
|
form_params = opts[:form_params] || {}
|
|
106
|
-
form_params['relative_path'] = relative_path
|
|
107
|
-
form_params['name'] = name
|
|
108
|
-
form_params['version'] = version
|
|
109
96
|
form_params['repository'] = opts[:'repository'] if !opts[:'repository'].nil?
|
|
110
97
|
form_params['pulp_labels'] = opts[:'pulp_labels'] if !opts[:'pulp_labels'].nil?
|
|
111
98
|
form_params['artifact'] = opts[:'artifact'] if !opts[:'artifact'].nil?
|
|
99
|
+
form_params['relative_path'] = opts[:'relative_path'] if !opts[:'relative_path'].nil?
|
|
112
100
|
form_params['file'] = opts[:'file'] if !opts[:'file'].nil?
|
|
113
101
|
form_params['upload'] = opts[:'upload'] if !opts[:'upload'].nil?
|
|
114
102
|
form_params['file_url'] = opts[:'file_url'] if !opts[:'file_url'].nil?
|
|
103
|
+
form_params['downloader_config'] = opts[:'downloader_config'] if !opts[:'downloader_config'].nil?
|
|
104
|
+
form_params['name'] = opts[:'name'] if !opts[:'name'].nil?
|
|
105
|
+
form_params['version'] = opts[:'version'] if !opts[:'version'].nil?
|
|
115
106
|
|
|
116
107
|
# http body (model)
|
|
117
108
|
post_body = opts[:debug_body]
|
|
118
109
|
|
|
119
110
|
# return_type
|
|
120
|
-
return_type = opts[:debug_return_type] || '
|
|
111
|
+
return_type = opts[:debug_return_type] || 'AsyncOperationResponse'
|
|
121
112
|
|
|
122
113
|
# auth_names
|
|
123
114
|
auth_names = opts[:debug_auth_names] || ['basicAuth']
|
|
@@ -140,7 +131,7 @@ module PulpNpmClient
|
|
|
140
131
|
end
|
|
141
132
|
|
|
142
133
|
# List packages
|
|
143
|
-
# A ViewSet for
|
|
134
|
+
# A ViewSet for NpmPackage. Define endpoint name which will appear in the API endpoint for this content type. For example:: http://pulp.example.com/pulp/api/v3/content/npm/packages/ Also specify queryset and serializer for NpmPackage.
|
|
144
135
|
# @param [Hash] opts the optional parameters
|
|
145
136
|
# @option opts [Array<String>] :x_task_diagnostics List of profilers to use on tasks.
|
|
146
137
|
# @option opts [Integer] :limit Number of results to return per page.
|
|
@@ -154,9 +145,9 @@ module PulpNpmClient
|
|
|
154
145
|
# @option opts [Array<String>] :pulp_id__in Multiple values may be separated by commas.
|
|
155
146
|
# @option opts [String] :pulp_label_select Filter labels by search string
|
|
156
147
|
# @option opts [String] :q Filter results by using NOT, AND and OR operations on other filters
|
|
157
|
-
# @option opts [String] :repository_version
|
|
158
|
-
# @option opts [String] :repository_version_added
|
|
159
|
-
# @option opts [String] :repository_version_removed
|
|
148
|
+
# @option opts [String] :repository_version
|
|
149
|
+
# @option opts [String] :repository_version_added
|
|
150
|
+
# @option opts [String] :repository_version_removed
|
|
160
151
|
# @option opts [Array<String>] :fields A list of fields to include in the response.
|
|
161
152
|
# @option opts [Array<String>] :exclude_fields A list of fields to exclude from the response.
|
|
162
153
|
# @return [PaginatednpmPackageResponseList]
|
|
@@ -166,7 +157,7 @@ module PulpNpmClient
|
|
|
166
157
|
end
|
|
167
158
|
|
|
168
159
|
# List packages
|
|
169
|
-
# A ViewSet for
|
|
160
|
+
# A ViewSet for NpmPackage. Define endpoint name which will appear in the API endpoint for this content type. For example:: http://pulp.example.com/pulp/api/v3/content/npm/packages/ Also specify queryset and serializer for NpmPackage.
|
|
170
161
|
# @param [Hash] opts the optional parameters
|
|
171
162
|
# @option opts [Array<String>] :x_task_diagnostics List of profilers to use on tasks.
|
|
172
163
|
# @option opts [Integer] :limit Number of results to return per page.
|
|
@@ -180,9 +171,9 @@ module PulpNpmClient
|
|
|
180
171
|
# @option opts [Array<String>] :pulp_id__in Multiple values may be separated by commas.
|
|
181
172
|
# @option opts [String] :pulp_label_select Filter labels by search string
|
|
182
173
|
# @option opts [String] :q Filter results by using NOT, AND and OR operations on other filters
|
|
183
|
-
# @option opts [String] :repository_version
|
|
184
|
-
# @option opts [String] :repository_version_added
|
|
185
|
-
# @option opts [String] :repository_version_removed
|
|
174
|
+
# @option opts [String] :repository_version
|
|
175
|
+
# @option opts [String] :repository_version_added
|
|
176
|
+
# @option opts [String] :repository_version_removed
|
|
186
177
|
# @option opts [Array<String>] :fields A list of fields to include in the response.
|
|
187
178
|
# @option opts [Array<String>] :exclude_fields A list of fields to exclude from the response.
|
|
188
179
|
# @return [Array<(PaginatednpmPackageResponseList, Integer, Hash)>] PaginatednpmPackageResponseList data, response status code and response headers
|
|
@@ -252,7 +243,7 @@ module PulpNpmClient
|
|
|
252
243
|
end
|
|
253
244
|
|
|
254
245
|
# Inspect a package
|
|
255
|
-
# A ViewSet for
|
|
246
|
+
# A ViewSet for NpmPackage. Define endpoint name which will appear in the API endpoint for this content type. For example:: http://pulp.example.com/pulp/api/v3/content/npm/packages/ Also specify queryset and serializer for NpmPackage.
|
|
256
247
|
# @param npm_package_href [String]
|
|
257
248
|
# @param [Hash] opts the optional parameters
|
|
258
249
|
# @option opts [Array<String>] :x_task_diagnostics List of profilers to use on tasks.
|
|
@@ -265,7 +256,7 @@ module PulpNpmClient
|
|
|
265
256
|
end
|
|
266
257
|
|
|
267
258
|
# Inspect a package
|
|
268
|
-
# A ViewSet for
|
|
259
|
+
# A ViewSet for NpmPackage. Define endpoint name which will appear in the API endpoint for this content type. For example:: http://pulp.example.com/pulp/api/v3/content/npm/packages/ Also specify queryset and serializer for NpmPackage.
|
|
269
260
|
# @param npm_package_href [String]
|
|
270
261
|
# @param [Hash] opts the optional parameters
|
|
271
262
|
# @option opts [Array<String>] :x_task_diagnostics List of profilers to use on tasks.
|
|
@@ -476,5 +467,113 @@ module PulpNpmClient
|
|
|
476
467
|
end
|
|
477
468
|
return data, status_code, headers
|
|
478
469
|
end
|
|
470
|
+
|
|
471
|
+
# Synchronous npm package upload
|
|
472
|
+
# Create an npm package content unit synchronously.
|
|
473
|
+
# @param [Hash] opts the optional parameters
|
|
474
|
+
# @option opts [Array<String>] :x_task_diagnostics List of profilers to use on tasks.
|
|
475
|
+
# @option opts [Hash<String, String>] :pulp_labels A dictionary of arbitrary key/value pairs used to describe a specific Content instance.
|
|
476
|
+
# @option opts [String] :artifact Artifact file representing the physical content
|
|
477
|
+
# @option opts [String] :relative_path Path where the artifact is located relative to distributions base_path. If not provided, it will be computed from name and version.
|
|
478
|
+
# @option opts [File] :file An uploaded file that may be turned into the content unit.
|
|
479
|
+
# @option opts [String] :upload An uncommitted upload that may be turned into the content unit.
|
|
480
|
+
# @option opts [String] :file_url A url that Pulp can download and turn into the content unit.
|
|
481
|
+
# @option opts [RemoteNetworkConfig] :downloader_config Configuration for the download process (e.g., proxies, auth, timeouts). Only applicable when providing a 'file_url.
|
|
482
|
+
# @option opts [String] :name The name of the npm package.
|
|
483
|
+
# @option opts [String] :version The version of the npm package.
|
|
484
|
+
# @return [NpmPackageResponse]
|
|
485
|
+
def upload(opts = {})
|
|
486
|
+
data, _status_code, _headers = upload_with_http_info(opts)
|
|
487
|
+
data
|
|
488
|
+
end
|
|
489
|
+
|
|
490
|
+
# Synchronous npm package upload
|
|
491
|
+
# Create an npm package content unit synchronously.
|
|
492
|
+
# @param [Hash] opts the optional parameters
|
|
493
|
+
# @option opts [Array<String>] :x_task_diagnostics List of profilers to use on tasks.
|
|
494
|
+
# @option opts [Hash<String, String>] :pulp_labels A dictionary of arbitrary key/value pairs used to describe a specific Content instance.
|
|
495
|
+
# @option opts [String] :artifact Artifact file representing the physical content
|
|
496
|
+
# @option opts [String] :relative_path Path where the artifact is located relative to distributions base_path. If not provided, it will be computed from name and version.
|
|
497
|
+
# @option opts [File] :file An uploaded file that may be turned into the content unit.
|
|
498
|
+
# @option opts [String] :upload An uncommitted upload that may be turned into the content unit.
|
|
499
|
+
# @option opts [String] :file_url A url that Pulp can download and turn into the content unit.
|
|
500
|
+
# @option opts [RemoteNetworkConfig] :downloader_config Configuration for the download process (e.g., proxies, auth, timeouts). Only applicable when providing a 'file_url.
|
|
501
|
+
# @option opts [String] :name The name of the npm package.
|
|
502
|
+
# @option opts [String] :version The version of the npm package.
|
|
503
|
+
# @return [Array<(NpmPackageResponse, Integer, Hash)>] NpmPackageResponse data, response status code and response headers
|
|
504
|
+
def upload_with_http_info(opts = {})
|
|
505
|
+
if @api_client.config.debugging
|
|
506
|
+
@api_client.config.logger.debug 'Calling API: ContentPackagesApi.upload ...'
|
|
507
|
+
end
|
|
508
|
+
if @api_client.config.client_side_validation && !opts[:'relative_path'].nil? && opts[:'relative_path'].to_s.length < 1
|
|
509
|
+
fail ArgumentError, 'invalid value for "opts[:"relative_path"]" when calling ContentPackagesApi.upload, the character length must be great than or equal to 1.'
|
|
510
|
+
end
|
|
511
|
+
|
|
512
|
+
if @api_client.config.client_side_validation && !opts[:'file_url'].nil? && opts[:'file_url'].to_s.length < 1
|
|
513
|
+
fail ArgumentError, 'invalid value for "opts[:"file_url"]" when calling ContentPackagesApi.upload, the character length must be great than or equal to 1.'
|
|
514
|
+
end
|
|
515
|
+
|
|
516
|
+
if @api_client.config.client_side_validation && !opts[:'name'].nil? && opts[:'name'].to_s.length < 1
|
|
517
|
+
fail ArgumentError, 'invalid value for "opts[:"name"]" when calling ContentPackagesApi.upload, the character length must be great than or equal to 1.'
|
|
518
|
+
end
|
|
519
|
+
|
|
520
|
+
if @api_client.config.client_side_validation && !opts[:'version'].nil? && opts[:'version'].to_s.length < 1
|
|
521
|
+
fail ArgumentError, 'invalid value for "opts[:"version"]" when calling ContentPackagesApi.upload, the character length must be great than or equal to 1.'
|
|
522
|
+
end
|
|
523
|
+
|
|
524
|
+
# resource path
|
|
525
|
+
local_var_path = '/pulp/api/v3/content/npm/packages/upload/'
|
|
526
|
+
|
|
527
|
+
# query parameters
|
|
528
|
+
query_params = opts[:query_params] || {}
|
|
529
|
+
|
|
530
|
+
# header parameters
|
|
531
|
+
header_params = opts[:header_params] || {}
|
|
532
|
+
# HTTP header 'Accept' (if needed)
|
|
533
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
|
534
|
+
# HTTP header 'Content-Type'
|
|
535
|
+
content_type = @api_client.select_header_content_type(['multipart/form-data', 'application/x-www-form-urlencoded'])
|
|
536
|
+
if !content_type.nil?
|
|
537
|
+
header_params['Content-Type'] = content_type
|
|
538
|
+
end
|
|
539
|
+
header_params[:'X-Task-Diagnostics'] = @api_client.build_collection_param(opts[:'x_task_diagnostics'], :csv) if !opts[:'x_task_diagnostics'].nil?
|
|
540
|
+
|
|
541
|
+
# form parameters
|
|
542
|
+
form_params = opts[:form_params] || {}
|
|
543
|
+
form_params['pulp_labels'] = opts[:'pulp_labels'] if !opts[:'pulp_labels'].nil?
|
|
544
|
+
form_params['artifact'] = opts[:'artifact'] if !opts[:'artifact'].nil?
|
|
545
|
+
form_params['relative_path'] = opts[:'relative_path'] if !opts[:'relative_path'].nil?
|
|
546
|
+
form_params['file'] = opts[:'file'] if !opts[:'file'].nil?
|
|
547
|
+
form_params['upload'] = opts[:'upload'] if !opts[:'upload'].nil?
|
|
548
|
+
form_params['file_url'] = opts[:'file_url'] if !opts[:'file_url'].nil?
|
|
549
|
+
form_params['downloader_config'] = opts[:'downloader_config'] if !opts[:'downloader_config'].nil?
|
|
550
|
+
form_params['name'] = opts[:'name'] if !opts[:'name'].nil?
|
|
551
|
+
form_params['version'] = opts[:'version'] if !opts[:'version'].nil?
|
|
552
|
+
|
|
553
|
+
# http body (model)
|
|
554
|
+
post_body = opts[:debug_body]
|
|
555
|
+
|
|
556
|
+
# return_type
|
|
557
|
+
return_type = opts[:debug_return_type] || 'NpmPackageResponse'
|
|
558
|
+
|
|
559
|
+
# auth_names
|
|
560
|
+
auth_names = opts[:debug_auth_names] || ['basicAuth']
|
|
561
|
+
|
|
562
|
+
new_options = opts.merge(
|
|
563
|
+
:operation => :"ContentPackagesApi.upload",
|
|
564
|
+
:header_params => header_params,
|
|
565
|
+
:query_params => query_params,
|
|
566
|
+
:form_params => form_params,
|
|
567
|
+
:body => post_body,
|
|
568
|
+
:auth_names => auth_names,
|
|
569
|
+
:return_type => return_type
|
|
570
|
+
)
|
|
571
|
+
|
|
572
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
|
573
|
+
if @api_client.config.debugging
|
|
574
|
+
@api_client.config.logger.debug "API called: ContentPackagesApi#upload\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
575
|
+
end
|
|
576
|
+
return data, status_code, headers
|
|
577
|
+
end
|
|
479
578
|
end
|
|
480
579
|
end
|
|
@@ -182,8 +182,8 @@ module PulpNpmClient
|
|
|
182
182
|
# @option opts [Array<String>] :pulp_id__in Multiple values may be separated by commas.
|
|
183
183
|
# @option opts [String] :pulp_label_select Filter labels by search string
|
|
184
184
|
# @option opts [String] :q Filter results by using NOT, AND and OR operations on other filters
|
|
185
|
-
# @option opts [String] :repository
|
|
186
|
-
# @option opts [Array<String>] :repository__in
|
|
185
|
+
# @option opts [String] :repository
|
|
186
|
+
# @option opts [Array<String>] :repository__in
|
|
187
187
|
# @option opts [String] :with_content Filter distributions based on the content served by them
|
|
188
188
|
# @option opts [Array<String>] :fields A list of fields to include in the response.
|
|
189
189
|
# @option opts [Array<String>] :exclude_fields A list of fields to exclude from the response.
|
|
@@ -219,8 +219,8 @@ module PulpNpmClient
|
|
|
219
219
|
# @option opts [Array<String>] :pulp_id__in Multiple values may be separated by commas.
|
|
220
220
|
# @option opts [String] :pulp_label_select Filter labels by search string
|
|
221
221
|
# @option opts [String] :q Filter results by using NOT, AND and OR operations on other filters
|
|
222
|
-
# @option opts [String] :repository
|
|
223
|
-
# @option opts [Array<String>] :repository__in
|
|
222
|
+
# @option opts [String] :repository
|
|
223
|
+
# @option opts [Array<String>] :repository__in
|
|
224
224
|
# @option opts [String] :with_content Filter distributions based on the content served by them
|
|
225
225
|
# @option opts [Array<String>] :fields A list of fields to include in the response.
|
|
226
226
|
# @option opts [Array<String>] :exclude_fields A list of fields to exclude from the response.
|
|
@@ -20,7 +20,7 @@ module PulpNpmClient
|
|
|
20
20
|
@api_client = api_client
|
|
21
21
|
end
|
|
22
22
|
# Create a npm remote
|
|
23
|
-
# A ViewSet for NpmRemote. Similar to the
|
|
23
|
+
# A ViewSet for NpmRemote. Similar to the NpmPackageViewSet above, define endpoint_name, queryset and serializer, at a minimum.
|
|
24
24
|
# @param npm_npm_remote [NpmNpmRemote]
|
|
25
25
|
# @param [Hash] opts the optional parameters
|
|
26
26
|
# @option opts [Array<String>] :x_task_diagnostics List of profilers to use on tasks.
|
|
@@ -31,7 +31,7 @@ module PulpNpmClient
|
|
|
31
31
|
end
|
|
32
32
|
|
|
33
33
|
# Create a npm remote
|
|
34
|
-
# A ViewSet for NpmRemote. Similar to the
|
|
34
|
+
# A ViewSet for NpmRemote. Similar to the NpmPackageViewSet above, define endpoint_name, queryset and serializer, at a minimum.
|
|
35
35
|
# @param npm_npm_remote [NpmNpmRemote]
|
|
36
36
|
# @param [Hash] opts the optional parameters
|
|
37
37
|
# @option opts [Array<String>] :x_task_diagnostics List of profilers to use on tasks.
|
|
@@ -157,7 +157,7 @@ module PulpNpmClient
|
|
|
157
157
|
end
|
|
158
158
|
|
|
159
159
|
# List npm remotes
|
|
160
|
-
# A ViewSet for NpmRemote. Similar to the
|
|
160
|
+
# A ViewSet for NpmRemote. Similar to the NpmPackageViewSet above, define endpoint_name, queryset and serializer, at a minimum.
|
|
161
161
|
# @param [Hash] opts the optional parameters
|
|
162
162
|
# @option opts [Array<String>] :x_task_diagnostics List of profilers to use on tasks.
|
|
163
163
|
# @option opts [Integer] :limit Number of results to return per page.
|
|
@@ -193,7 +193,7 @@ module PulpNpmClient
|
|
|
193
193
|
end
|
|
194
194
|
|
|
195
195
|
# List npm remotes
|
|
196
|
-
# A ViewSet for NpmRemote. Similar to the
|
|
196
|
+
# A ViewSet for NpmRemote. Similar to the NpmPackageViewSet above, define endpoint_name, queryset and serializer, at a minimum.
|
|
197
197
|
# @param [Hash] opts the optional parameters
|
|
198
198
|
# @option opts [Array<String>] :x_task_diagnostics List of profilers to use on tasks.
|
|
199
199
|
# @option opts [Integer] :limit Number of results to return per page.
|
|
@@ -376,7 +376,7 @@ module PulpNpmClient
|
|
|
376
376
|
end
|
|
377
377
|
|
|
378
378
|
# Inspect a npm remote
|
|
379
|
-
# A ViewSet for NpmRemote. Similar to the
|
|
379
|
+
# A ViewSet for NpmRemote. Similar to the NpmPackageViewSet above, define endpoint_name, queryset and serializer, at a minimum.
|
|
380
380
|
# @param npm_npm_remote_href [String]
|
|
381
381
|
# @param [Hash] opts the optional parameters
|
|
382
382
|
# @option opts [Array<String>] :x_task_diagnostics List of profilers to use on tasks.
|
|
@@ -389,7 +389,7 @@ module PulpNpmClient
|
|
|
389
389
|
end
|
|
390
390
|
|
|
391
391
|
# Inspect a npm remote
|
|
392
|
-
# A ViewSet for NpmRemote. Similar to the
|
|
392
|
+
# A ViewSet for NpmRemote. Similar to the NpmPackageViewSet above, define endpoint_name, queryset and serializer, at a minimum.
|
|
393
393
|
# @param npm_npm_remote_href [String]
|
|
394
394
|
# @param [Hash] opts the optional parameters
|
|
395
395
|
# @option opts [Array<String>] :x_task_diagnostics List of profilers to use on tasks.
|
|
@@ -20,7 +20,7 @@ module PulpNpmClient
|
|
|
20
20
|
@api_client = api_client
|
|
21
21
|
end
|
|
22
22
|
# Create a npm repository
|
|
23
|
-
# A ViewSet for NpmRepository. Similar to the
|
|
23
|
+
# A ViewSet for NpmRepository. Similar to the NpmPackageViewSet above, define endpoint_name, queryset and serializer, at a minimum.
|
|
24
24
|
# @param npm_npm_repository [NpmNpmRepository]
|
|
25
25
|
# @param [Hash] opts the optional parameters
|
|
26
26
|
# @option opts [Array<String>] :x_task_diagnostics List of profilers to use on tasks.
|
|
@@ -31,7 +31,7 @@ module PulpNpmClient
|
|
|
31
31
|
end
|
|
32
32
|
|
|
33
33
|
# Create a npm repository
|
|
34
|
-
# A ViewSet for NpmRepository. Similar to the
|
|
34
|
+
# A ViewSet for NpmRepository. Similar to the NpmPackageViewSet above, define endpoint_name, queryset and serializer, at a minimum.
|
|
35
35
|
# @param npm_npm_repository [NpmNpmRepository]
|
|
36
36
|
# @param [Hash] opts the optional parameters
|
|
37
37
|
# @option opts [Array<String>] :x_task_diagnostics List of profilers to use on tasks.
|
|
@@ -157,7 +157,7 @@ module PulpNpmClient
|
|
|
157
157
|
end
|
|
158
158
|
|
|
159
159
|
# List npm repositorys
|
|
160
|
-
# A ViewSet for NpmRepository. Similar to the
|
|
160
|
+
# A ViewSet for NpmRepository. Similar to the NpmPackageViewSet above, define endpoint_name, queryset and serializer, at a minimum.
|
|
161
161
|
# @param [Hash] opts the optional parameters
|
|
162
162
|
# @option opts [Array<String>] :x_task_diagnostics List of profilers to use on tasks.
|
|
163
163
|
# @option opts [String] :latest_with_content Content Unit referenced by HREF/PRN
|
|
@@ -178,7 +178,7 @@ module PulpNpmClient
|
|
|
178
178
|
# @option opts [Array<String>] :pulp_id__in Multiple values may be separated by commas.
|
|
179
179
|
# @option opts [String] :pulp_label_select Filter labels by search string
|
|
180
180
|
# @option opts [String] :q Filter results by using NOT, AND and OR operations on other filters
|
|
181
|
-
# @option opts [String] :remote
|
|
181
|
+
# @option opts [String] :remote
|
|
182
182
|
# @option opts [Integer] :retain_repo_versions Filter results where retain_repo_versions matches value
|
|
183
183
|
# @option opts [Integer] :retain_repo_versions__gt Filter results where retain_repo_versions is greater than value
|
|
184
184
|
# @option opts [Integer] :retain_repo_versions__gte Filter results where retain_repo_versions is greater than or equal to value
|
|
@@ -197,7 +197,7 @@ module PulpNpmClient
|
|
|
197
197
|
end
|
|
198
198
|
|
|
199
199
|
# List npm repositorys
|
|
200
|
-
# A ViewSet for NpmRepository. Similar to the
|
|
200
|
+
# A ViewSet for NpmRepository. Similar to the NpmPackageViewSet above, define endpoint_name, queryset and serializer, at a minimum.
|
|
201
201
|
# @param [Hash] opts the optional parameters
|
|
202
202
|
# @option opts [Array<String>] :x_task_diagnostics List of profilers to use on tasks.
|
|
203
203
|
# @option opts [String] :latest_with_content Content Unit referenced by HREF/PRN
|
|
@@ -218,7 +218,7 @@ module PulpNpmClient
|
|
|
218
218
|
# @option opts [Array<String>] :pulp_id__in Multiple values may be separated by commas.
|
|
219
219
|
# @option opts [String] :pulp_label_select Filter labels by search string
|
|
220
220
|
# @option opts [String] :q Filter results by using NOT, AND and OR operations on other filters
|
|
221
|
-
# @option opts [String] :remote
|
|
221
|
+
# @option opts [String] :remote
|
|
222
222
|
# @option opts [Integer] :retain_repo_versions Filter results where retain_repo_versions matches value
|
|
223
223
|
# @option opts [Integer] :retain_repo_versions__gt Filter results where retain_repo_versions is greater than value
|
|
224
224
|
# @option opts [Integer] :retain_repo_versions__gte Filter results where retain_repo_versions is greater than or equal to value
|
|
@@ -465,7 +465,7 @@ module PulpNpmClient
|
|
|
465
465
|
end
|
|
466
466
|
|
|
467
467
|
# Inspect a npm repository
|
|
468
|
-
# A ViewSet for NpmRepository. Similar to the
|
|
468
|
+
# A ViewSet for NpmRepository. Similar to the NpmPackageViewSet above, define endpoint_name, queryset and serializer, at a minimum.
|
|
469
469
|
# @param npm_npm_repository_href [String]
|
|
470
470
|
# @param [Hash] opts the optional parameters
|
|
471
471
|
# @option opts [Array<String>] :x_task_diagnostics List of profilers to use on tasks.
|
|
@@ -478,7 +478,7 @@ module PulpNpmClient
|
|
|
478
478
|
end
|
|
479
479
|
|
|
480
480
|
# Inspect a npm repository
|
|
481
|
-
# A ViewSet for NpmRepository. Similar to the
|
|
481
|
+
# A ViewSet for NpmRepository. Similar to the NpmPackageViewSet above, define endpoint_name, queryset and serializer, at a minimum.
|
|
482
482
|
# @param npm_npm_repository_href [String]
|
|
483
483
|
# @param [Hash] opts the optional parameters
|
|
484
484
|
# @option opts [Array<String>] :x_task_diagnostics List of profilers to use on tasks.
|