cloudsmith-api 2.0.2 → 2.0.4
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/Gemfile.lock +2 -2
- data/README.md +13 -5
- data/build.json +1 -1
- data/docs/Eula.md +1 -1
- data/docs/HelmPackageUploadRequest.md +1 -0
- data/docs/HexPackageUpload.md +75 -0
- data/docs/HexPackageUploadRequest.md +10 -0
- data/docs/NestedLicensePolicy.md +1 -0
- data/docs/NestedVulnerabilityPolicy.md +1 -0
- data/docs/NestedVulnerabilityScanResults.md +1 -1
- data/docs/OrganizationPackageLicensePolicy.md +1 -0
- data/docs/OrganizationPackageLicensePolicyRequest.md +1 -0
- data/docs/OrganizationPackageLicensePolicyRequestPatch.md +1 -0
- data/docs/OrganizationPackageVulnerabilityPolicy.md +1 -0
- data/docs/OrganizationPackageVulnerabilityPolicyRequest.md +1 -0
- data/docs/OrganizationPackageVulnerabilityPolicyRequestPatch.md +1 -0
- data/docs/PackagesApi.md +246 -0
- data/docs/RepositoryToken.md +1 -1
- data/docs/RepositoryTokenRefresh.md +1 -1
- data/docs/RepositoryWebhook.md +1 -1
- data/docs/StatusBasic.md +1 -1
- data/docs/SwiftPackageUpload.md +75 -0
- data/docs/SwiftPackageUploadRequest.md +11 -0
- data/docs/VulnerabilitiesApi.md +8 -8
- data/docs/VulnerabilityScanResults.md +1 -1
- data/docs/VulnerabilityScanResultsList.md +1 -1
- data/lib/cloudsmith-api/api/packages_api.rb +246 -0
- data/lib/cloudsmith-api/api/vulnerabilities_api.rb +13 -13
- data/lib/cloudsmith-api/models/eula.rb +0 -5
- data/lib/cloudsmith-api/models/helm_package_upload_request.rb +11 -1
- data/lib/cloudsmith-api/models/hex_package_upload.rb +850 -0
- data/lib/cloudsmith-api/models/hex_package_upload_request.rb +210 -0
- data/lib/cloudsmith-api/models/nested_license_policy.rb +10 -1
- data/lib/cloudsmith-api/models/nested_vulnerability_policy.rb +10 -1
- data/lib/cloudsmith-api/models/nested_vulnerability_scan_results.rb +1 -0
- data/lib/cloudsmith-api/models/organization_package_license_policy.rb +10 -1
- data/lib/cloudsmith-api/models/organization_package_license_policy_request.rb +10 -1
- data/lib/cloudsmith-api/models/organization_package_license_policy_request_patch.rb +10 -1
- data/lib/cloudsmith-api/models/organization_package_vulnerability_policy.rb +10 -1
- data/lib/cloudsmith-api/models/organization_package_vulnerability_policy_request.rb +13 -4
- data/lib/cloudsmith-api/models/organization_package_vulnerability_policy_request_patch.rb +13 -4
- data/lib/cloudsmith-api/models/repository_token.rb +1 -0
- data/lib/cloudsmith-api/models/repository_token_refresh.rb +1 -0
- data/lib/cloudsmith-api/models/repository_webhook.rb +1 -0
- data/lib/cloudsmith-api/models/status_basic.rb +1 -1
- data/lib/cloudsmith-api/models/swift_package_upload.rb +855 -0
- data/lib/cloudsmith-api/models/swift_package_upload_request.rb +225 -0
- data/lib/cloudsmith-api/models/vulnerability_scan_results.rb +1 -0
- data/lib/cloudsmith-api/models/vulnerability_scan_results_list.rb +1 -0
- data/lib/cloudsmith-api/version.rb +1 -1
- data/lib/cloudsmith-api.rb +4 -0
- data/spec/api/packages_api_spec.rb +56 -0
- data/spec/api/vulnerabilities_api_spec.rb +3 -3
- data/spec/models/helm_package_upload_request_spec.rb +6 -0
- data/spec/models/hex_package_upload_request_spec.rb +53 -0
- data/spec/models/hex_package_upload_spec.rb +447 -0
- data/spec/models/nested_license_policy_spec.rb +6 -0
- data/spec/models/nested_vulnerability_policy_spec.rb +6 -0
- data/spec/models/organization_package_license_policy_request_patch_spec.rb +6 -0
- data/spec/models/organization_package_license_policy_request_spec.rb +6 -0
- data/spec/models/organization_package_license_policy_spec.rb +6 -0
- data/spec/models/organization_package_vulnerability_policy_request_patch_spec.rb +6 -0
- data/spec/models/organization_package_vulnerability_policy_request_spec.rb +6 -0
- data/spec/models/organization_package_vulnerability_policy_spec.rb +6 -0
- data/spec/models/swift_package_upload_request_spec.rb +59 -0
- data/spec/models/swift_package_upload_spec.rb +447 -0
- data/vendor/bundle/ruby/2.6.0/extensions/x86_64-linux/2.6.0/autotest-fsevent-0.2.20/gem_make.out +1 -1
- data/vendor/bundle/ruby/2.6.0/extensions/x86_64-linux/2.6.0/ffi-1.15.5/gem_make.out +2 -2
- data/vendor/bundle/ruby/2.6.0/extensions/x86_64-linux/2.6.0/json-2.6.3/gem_make.out +1 -1
- data/vendor/bundle/ruby/2.6.0/extensions/x86_64-linux/2.6.0/json-2.6.3/mkmf.log +1 -1
- data/vendor/bundle/ruby/2.6.0/gems/ffi-1.15.5/ext/ffi_c/Makefile +2 -2
- data/vendor/bundle/ruby/2.6.0/gems/json-2.6.3/ext/json/Makefile +2 -2
- data/vendor/bundle/ruby/2.6.0/gems/json-2.6.3/ext/json/ext/generator/Makefile +2 -2
- data/vendor/bundle/ruby/2.6.0/gems/json-2.6.3/ext/json/ext/parser/Makefile +2 -2
- metadata +18 -2
data/docs/StatusBasic.md
CHANGED
@@ -4,6 +4,6 @@
|
|
4
4
|
Name | Type | Description | Notes
|
5
5
|
------------ | ------------- | ------------- | -------------
|
6
6
|
**detail** | **String** | The message describing the state of the API. | [optional] [default to 'Cloudsmith API is operational.']
|
7
|
-
**version** | **String** | The current version for the Cloudsmith service. | [optional] [default to '1.
|
7
|
+
**version** | **String** | The current version for the Cloudsmith service. | [optional] [default to '1.273.0']
|
8
8
|
|
9
9
|
|
@@ -0,0 +1,75 @@
|
|
1
|
+
# CloudsmithApi::SwiftPackageUpload
|
2
|
+
|
3
|
+
## Properties
|
4
|
+
Name | Type | Description | Notes
|
5
|
+
------------ | ------------- | ------------- | -------------
|
6
|
+
**architectures** | [**Array<Architecture>**](Architecture.md) | | [optional]
|
7
|
+
**cdn_url** | **String** | | [optional]
|
8
|
+
**checksum_md5** | **String** | | [optional]
|
9
|
+
**checksum_sha1** | **String** | | [optional]
|
10
|
+
**checksum_sha256** | **String** | | [optional]
|
11
|
+
**checksum_sha512** | **String** | | [optional]
|
12
|
+
**dependencies_checksum_md5** | **String** | A checksum of all of the package's dependencies. | [optional]
|
13
|
+
**dependencies_url** | **String** | | [optional]
|
14
|
+
**description** | **String** | A textual description of this package. | [optional]
|
15
|
+
**distro** | [**Distribution**](Distribution.md) | | [optional]
|
16
|
+
**distro_version** | [**DistributionVersion**](DistributionVersion.md) | | [optional]
|
17
|
+
**downloads** | **Integer** | | [optional]
|
18
|
+
**epoch** | **Integer** | The epoch of the package version (if any). | [optional]
|
19
|
+
**extension** | **String** | | [optional]
|
20
|
+
**filename** | **String** | | [optional]
|
21
|
+
**files** | [**Array<PackageFile>**](PackageFile.md) | | [optional]
|
22
|
+
**format** | **String** | | [optional]
|
23
|
+
**format_url** | **String** | | [optional]
|
24
|
+
**identifier_perm** | **String** | Unique and permanent identifier for the package. | [optional]
|
25
|
+
**indexed** | **BOOLEAN** | | [optional]
|
26
|
+
**is_downloadable** | **BOOLEAN** | | [optional]
|
27
|
+
**is_quarantined** | **BOOLEAN** | | [optional]
|
28
|
+
**is_sync_awaiting** | **BOOLEAN** | | [optional]
|
29
|
+
**is_sync_completed** | **BOOLEAN** | | [optional]
|
30
|
+
**is_sync_failed** | **BOOLEAN** | | [optional]
|
31
|
+
**is_sync_in_flight** | **BOOLEAN** | | [optional]
|
32
|
+
**is_sync_in_progress** | **BOOLEAN** | | [optional]
|
33
|
+
**license** | **String** | The license of this package. | [optional]
|
34
|
+
**name** | **String** | The name of this package. | [optional]
|
35
|
+
**namespace** | **String** | | [optional]
|
36
|
+
**namespace_url** | **String** | | [optional]
|
37
|
+
**num_files** | **Integer** | | [optional]
|
38
|
+
**origin_repository** | **String** | | [optional]
|
39
|
+
**origin_repository_url** | **String** | | [optional]
|
40
|
+
**package_type** | **Integer** | The type of package contents. | [optional]
|
41
|
+
**release** | **String** | The release of the package version (if any). | [optional]
|
42
|
+
**repository** | **String** | | [optional]
|
43
|
+
**repository_url** | **String** | | [optional]
|
44
|
+
**security_scan_completed_at** | **DateTime** | The datetime the security scanning was completed. | [optional]
|
45
|
+
**security_scan_started_at** | **DateTime** | The datetime the security scanning was started. | [optional]
|
46
|
+
**security_scan_status** | **String** | | [optional] [default to 'Awaiting Security Scan']
|
47
|
+
**security_scan_status_updated_at** | **DateTime** | The datetime the security scanning status was updated. | [optional]
|
48
|
+
**self_html_url** | **String** | | [optional]
|
49
|
+
**self_url** | **String** | | [optional]
|
50
|
+
**signature_url** | **String** | | [optional]
|
51
|
+
**size** | **Integer** | The calculated size of the package. | [optional]
|
52
|
+
**slug** | **String** | The public unique identifier for the package. | [optional]
|
53
|
+
**slug_perm** | **String** | | [optional]
|
54
|
+
**stage** | **Integer** | The synchronisation (in progress) stage of the package. | [optional]
|
55
|
+
**stage_str** | **String** | | [optional]
|
56
|
+
**stage_updated_at** | **DateTime** | The datetime the package stage was updated at. | [optional]
|
57
|
+
**status** | **Integer** | The synchronisation status of the package. | [optional]
|
58
|
+
**status_reason** | **String** | A textual description for the synchronous status reason (if any | [optional]
|
59
|
+
**status_str** | **String** | | [optional]
|
60
|
+
**status_updated_at** | **DateTime** | The datetime the package status was updated at. | [optional]
|
61
|
+
**status_url** | **String** | | [optional]
|
62
|
+
**subtype** | **String** | | [optional]
|
63
|
+
**summary** | **String** | A one-liner synopsis of this package. | [optional]
|
64
|
+
**sync_finished_at** | **DateTime** | The datetime the package sync was finished at. | [optional]
|
65
|
+
**sync_progress** | **Integer** | Synchronisation progress (from 0-100) | [optional]
|
66
|
+
**tags_immutable** | [**Tags**](Tags.md) | | [optional]
|
67
|
+
**type_display** | **String** | | [optional]
|
68
|
+
**uploaded_at** | **DateTime** | The date this package was uploaded. | [optional]
|
69
|
+
**uploader** | **String** | | [optional]
|
70
|
+
**uploader_url** | **String** | | [optional]
|
71
|
+
**version** | **String** | The raw version for this package. |
|
72
|
+
**version_orig** | **String** | | [optional]
|
73
|
+
**vulnerability_scan_results_url** | **String** | | [optional]
|
74
|
+
|
75
|
+
|
@@ -0,0 +1,11 @@
|
|
1
|
+
# CloudsmithApi::SwiftPackageUploadRequest
|
2
|
+
|
3
|
+
## Properties
|
4
|
+
Name | Type | Description | Notes
|
5
|
+
------------ | ------------- | ------------- | -------------
|
6
|
+
**package_file** | **String** | The primary file for the package. |
|
7
|
+
**republish** | **BOOLEAN** | If true, the uploaded package will overwrite any others with the same attributes (e.g. same version); otherwise, it will be flagged as a duplicate. | [optional]
|
8
|
+
**tags** | **String** | A comma-separated values list of tags to add to the package. | [optional]
|
9
|
+
**version** | **String** | The raw version for this package. |
|
10
|
+
|
11
|
+
|
data/docs/VulnerabilitiesApi.md
CHANGED
@@ -6,7 +6,7 @@ Method | HTTP request | Description
|
|
6
6
|
------------- | ------------- | -------------
|
7
7
|
[**vulnerabilities_namespace_list**](VulnerabilitiesApi.md#vulnerabilities_namespace_list) | **GET** /vulnerabilities/{owner}/ | Lists scan results for a specific namespace.
|
8
8
|
[**vulnerabilities_package_list**](VulnerabilitiesApi.md#vulnerabilities_package_list) | **GET** /vulnerabilities/{owner}/{repo}/{package}/ | Lists scan results for a specific package.
|
9
|
-
[**vulnerabilities_read**](VulnerabilitiesApi.md#vulnerabilities_read) | **GET** /vulnerabilities/{owner}/{repo}/{package}/{
|
9
|
+
[**vulnerabilities_read**](VulnerabilitiesApi.md#vulnerabilities_read) | **GET** /vulnerabilities/{owner}/{repo}/{package}/{identifier}/ | Get a scan result.
|
10
10
|
[**vulnerabilities_repo_list**](VulnerabilitiesApi.md#vulnerabilities_repo_list) | **GET** /vulnerabilities/{owner}/{repo}/ | Lists scan results for a specific repository.
|
11
11
|
|
12
12
|
|
@@ -137,11 +137,11 @@ Name | Type | Description | Notes
|
|
137
137
|
|
138
138
|
|
139
139
|
# **vulnerabilities_read**
|
140
|
-
> VulnerabilityScanResults vulnerabilities_read(owner, repo, package,
|
140
|
+
> VulnerabilityScanResults vulnerabilities_read(owner, repo, package, identifier)
|
141
141
|
|
142
|
-
|
142
|
+
Get a scan result.
|
143
143
|
|
144
|
-
|
144
|
+
Get a scan result.
|
145
145
|
|
146
146
|
### Example
|
147
147
|
```ruby
|
@@ -163,12 +163,12 @@ repo = 'repo_example' # String |
|
|
163
163
|
|
164
164
|
package = 'package_example' # String |
|
165
165
|
|
166
|
-
|
166
|
+
identifier = 'identifier_example' # String |
|
167
167
|
|
168
168
|
|
169
169
|
begin
|
170
|
-
#
|
171
|
-
result = api_instance.vulnerabilities_read(owner, repo, package,
|
170
|
+
#Get a scan result.
|
171
|
+
result = api_instance.vulnerabilities_read(owner, repo, package, identifier)
|
172
172
|
p result
|
173
173
|
rescue CloudsmithApi::ApiError => e
|
174
174
|
puts "Exception when calling VulnerabilitiesApi->vulnerabilities_read: #{e}"
|
@@ -182,7 +182,7 @@ Name | Type | Description | Notes
|
|
182
182
|
**owner** | **String**| |
|
183
183
|
**repo** | **String**| |
|
184
184
|
**package** | **String**| |
|
185
|
-
**
|
185
|
+
**identifier** | **String**| |
|
186
186
|
|
187
187
|
### Return type
|
188
188
|
|
@@ -10,6 +10,6 @@ Name | Type | Description | Notes
|
|
10
10
|
**num_vulnerabilities** | **Integer** | | [optional]
|
11
11
|
**package** | [**PackageVulnerability**](PackageVulnerability.md) | |
|
12
12
|
**scan** | [**VulnerabilityScan**](VulnerabilityScan.md) | |
|
13
|
-
**scan_id** | **Integer** |
|
13
|
+
**scan_id** | **Integer** | Deprecated (23-05-15): Please use 'identifier' instead. Previously: A monotonically increasing number that identified a scan within a repository. |
|
14
14
|
|
15
15
|
|
@@ -9,6 +9,6 @@ Name | Type | Description | Notes
|
|
9
9
|
**max_severity** | **String** | | [optional] [default to 'Unknown']
|
10
10
|
**num_vulnerabilities** | **Integer** | | [optional]
|
11
11
|
**package** | [**PackageVulnerability**](PackageVulnerability.md) | |
|
12
|
-
**scan_id** | **Integer** |
|
12
|
+
**scan_id** | **Integer** | Deprecated (23-05-15): Please use 'identifier' instead. Previously: A monotonically increasing number that identified a scan within a repository. |
|
13
13
|
|
14
14
|
|
@@ -1502,6 +1502,68 @@ module CloudsmithApi
|
|
1502
1502
|
end
|
1503
1503
|
return data, status_code, headers
|
1504
1504
|
end
|
1505
|
+
# Create a new Hex package
|
1506
|
+
# Create a new Hex package
|
1507
|
+
# @param owner
|
1508
|
+
# @param repo
|
1509
|
+
# @param [Hash] opts the optional parameters
|
1510
|
+
# @option opts [HexPackageUploadRequest] :data
|
1511
|
+
# @return [HexPackageUpload]
|
1512
|
+
def packages_upload_hex(owner, repo, opts = {})
|
1513
|
+
data, _status_code, _headers = packages_upload_hex_with_http_info(owner, repo, opts)
|
1514
|
+
data
|
1515
|
+
end
|
1516
|
+
|
1517
|
+
# Create a new Hex package
|
1518
|
+
# Create a new Hex package
|
1519
|
+
# @param owner
|
1520
|
+
# @param repo
|
1521
|
+
# @param [Hash] opts the optional parameters
|
1522
|
+
# @option opts [HexPackageUploadRequest] :data
|
1523
|
+
# @return [Array<(HexPackageUpload, Fixnum, Hash)>] HexPackageUpload data, response status code and response headers
|
1524
|
+
def packages_upload_hex_with_http_info(owner, repo, opts = {})
|
1525
|
+
if @api_client.config.debugging
|
1526
|
+
@api_client.config.logger.debug 'Calling API: PackagesApi.packages_upload_hex ...'
|
1527
|
+
end
|
1528
|
+
# verify the required parameter 'owner' is set
|
1529
|
+
if @api_client.config.client_side_validation && owner.nil?
|
1530
|
+
fail ArgumentError, "Missing the required parameter 'owner' when calling PackagesApi.packages_upload_hex"
|
1531
|
+
end
|
1532
|
+
# verify the required parameter 'repo' is set
|
1533
|
+
if @api_client.config.client_side_validation && repo.nil?
|
1534
|
+
fail ArgumentError, "Missing the required parameter 'repo' when calling PackagesApi.packages_upload_hex"
|
1535
|
+
end
|
1536
|
+
# resource path
|
1537
|
+
local_var_path = '/packages/{owner}/{repo}/upload/hex/'.sub('{' + 'owner' + '}', owner.to_s).sub('{' + 'repo' + '}', repo.to_s)
|
1538
|
+
|
1539
|
+
# query parameters
|
1540
|
+
query_params = {}
|
1541
|
+
|
1542
|
+
# header parameters
|
1543
|
+
header_params = {}
|
1544
|
+
# HTTP header 'Accept' (if needed)
|
1545
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
1546
|
+
# HTTP header 'Content-Type'
|
1547
|
+
header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
|
1548
|
+
|
1549
|
+
# form parameters
|
1550
|
+
form_params = {}
|
1551
|
+
|
1552
|
+
# http body (model)
|
1553
|
+
post_body = @api_client.object_to_http_body(opts[:'data'])
|
1554
|
+
auth_names = ['apikey']
|
1555
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path,
|
1556
|
+
:header_params => header_params,
|
1557
|
+
:query_params => query_params,
|
1558
|
+
:form_params => form_params,
|
1559
|
+
:body => post_body,
|
1560
|
+
:auth_names => auth_names,
|
1561
|
+
:return_type => 'HexPackageUpload')
|
1562
|
+
if @api_client.config.debugging
|
1563
|
+
@api_client.config.logger.debug "API called: PackagesApi#packages_upload_hex\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
1564
|
+
end
|
1565
|
+
return data, status_code, headers
|
1566
|
+
end
|
1505
1567
|
# Create a new LuaRocks package
|
1506
1568
|
# Create a new LuaRocks package
|
1507
1569
|
# @param owner
|
@@ -2060,6 +2122,68 @@ module CloudsmithApi
|
|
2060
2122
|
end
|
2061
2123
|
return data, status_code, headers
|
2062
2124
|
end
|
2125
|
+
# Create a new Swift package
|
2126
|
+
# Create a new Swift package
|
2127
|
+
# @param owner
|
2128
|
+
# @param repo
|
2129
|
+
# @param [Hash] opts the optional parameters
|
2130
|
+
# @option opts [SwiftPackageUploadRequest] :data
|
2131
|
+
# @return [SwiftPackageUpload]
|
2132
|
+
def packages_upload_swift(owner, repo, opts = {})
|
2133
|
+
data, _status_code, _headers = packages_upload_swift_with_http_info(owner, repo, opts)
|
2134
|
+
data
|
2135
|
+
end
|
2136
|
+
|
2137
|
+
# Create a new Swift package
|
2138
|
+
# Create a new Swift package
|
2139
|
+
# @param owner
|
2140
|
+
# @param repo
|
2141
|
+
# @param [Hash] opts the optional parameters
|
2142
|
+
# @option opts [SwiftPackageUploadRequest] :data
|
2143
|
+
# @return [Array<(SwiftPackageUpload, Fixnum, Hash)>] SwiftPackageUpload data, response status code and response headers
|
2144
|
+
def packages_upload_swift_with_http_info(owner, repo, opts = {})
|
2145
|
+
if @api_client.config.debugging
|
2146
|
+
@api_client.config.logger.debug 'Calling API: PackagesApi.packages_upload_swift ...'
|
2147
|
+
end
|
2148
|
+
# verify the required parameter 'owner' is set
|
2149
|
+
if @api_client.config.client_side_validation && owner.nil?
|
2150
|
+
fail ArgumentError, "Missing the required parameter 'owner' when calling PackagesApi.packages_upload_swift"
|
2151
|
+
end
|
2152
|
+
# verify the required parameter 'repo' is set
|
2153
|
+
if @api_client.config.client_side_validation && repo.nil?
|
2154
|
+
fail ArgumentError, "Missing the required parameter 'repo' when calling PackagesApi.packages_upload_swift"
|
2155
|
+
end
|
2156
|
+
# resource path
|
2157
|
+
local_var_path = '/packages/{owner}/{repo}/upload/swift/'.sub('{' + 'owner' + '}', owner.to_s).sub('{' + 'repo' + '}', repo.to_s)
|
2158
|
+
|
2159
|
+
# query parameters
|
2160
|
+
query_params = {}
|
2161
|
+
|
2162
|
+
# header parameters
|
2163
|
+
header_params = {}
|
2164
|
+
# HTTP header 'Accept' (if needed)
|
2165
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
2166
|
+
# HTTP header 'Content-Type'
|
2167
|
+
header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
|
2168
|
+
|
2169
|
+
# form parameters
|
2170
|
+
form_params = {}
|
2171
|
+
|
2172
|
+
# http body (model)
|
2173
|
+
post_body = @api_client.object_to_http_body(opts[:'data'])
|
2174
|
+
auth_names = ['apikey']
|
2175
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path,
|
2176
|
+
:header_params => header_params,
|
2177
|
+
:query_params => query_params,
|
2178
|
+
:form_params => form_params,
|
2179
|
+
:body => post_body,
|
2180
|
+
:auth_names => auth_names,
|
2181
|
+
:return_type => 'SwiftPackageUpload')
|
2182
|
+
if @api_client.config.debugging
|
2183
|
+
@api_client.config.logger.debug "API called: PackagesApi#packages_upload_swift\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
2184
|
+
end
|
2185
|
+
return data, status_code, headers
|
2186
|
+
end
|
2063
2187
|
# Create a new Terraform package
|
2064
2188
|
# Create a new Terraform package
|
2065
2189
|
# @param owner
|
@@ -2916,6 +3040,67 @@ module CloudsmithApi
|
|
2916
3040
|
end
|
2917
3041
|
return data, status_code, headers
|
2918
3042
|
end
|
3043
|
+
# Validate parameters for create Hex package
|
3044
|
+
# Validate parameters for create Hex package
|
3045
|
+
# @param owner
|
3046
|
+
# @param repo
|
3047
|
+
# @param [Hash] opts the optional parameters
|
3048
|
+
# @option opts [HexPackageUploadRequest] :data
|
3049
|
+
# @return [nil]
|
3050
|
+
def packages_validate_upload_hex(owner, repo, opts = {})
|
3051
|
+
packages_validate_upload_hex_with_http_info(owner, repo, opts)
|
3052
|
+
nil
|
3053
|
+
end
|
3054
|
+
|
3055
|
+
# Validate parameters for create Hex package
|
3056
|
+
# Validate parameters for create Hex package
|
3057
|
+
# @param owner
|
3058
|
+
# @param repo
|
3059
|
+
# @param [Hash] opts the optional parameters
|
3060
|
+
# @option opts [HexPackageUploadRequest] :data
|
3061
|
+
# @return [Array<(nil, Fixnum, Hash)>] nil, response status code and response headers
|
3062
|
+
def packages_validate_upload_hex_with_http_info(owner, repo, opts = {})
|
3063
|
+
if @api_client.config.debugging
|
3064
|
+
@api_client.config.logger.debug 'Calling API: PackagesApi.packages_validate_upload_hex ...'
|
3065
|
+
end
|
3066
|
+
# verify the required parameter 'owner' is set
|
3067
|
+
if @api_client.config.client_side_validation && owner.nil?
|
3068
|
+
fail ArgumentError, "Missing the required parameter 'owner' when calling PackagesApi.packages_validate_upload_hex"
|
3069
|
+
end
|
3070
|
+
# verify the required parameter 'repo' is set
|
3071
|
+
if @api_client.config.client_side_validation && repo.nil?
|
3072
|
+
fail ArgumentError, "Missing the required parameter 'repo' when calling PackagesApi.packages_validate_upload_hex"
|
3073
|
+
end
|
3074
|
+
# resource path
|
3075
|
+
local_var_path = '/packages/{owner}/{repo}/validate-upload/hex/'.sub('{' + 'owner' + '}', owner.to_s).sub('{' + 'repo' + '}', repo.to_s)
|
3076
|
+
|
3077
|
+
# query parameters
|
3078
|
+
query_params = {}
|
3079
|
+
|
3080
|
+
# header parameters
|
3081
|
+
header_params = {}
|
3082
|
+
# HTTP header 'Accept' (if needed)
|
3083
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
3084
|
+
# HTTP header 'Content-Type'
|
3085
|
+
header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
|
3086
|
+
|
3087
|
+
# form parameters
|
3088
|
+
form_params = {}
|
3089
|
+
|
3090
|
+
# http body (model)
|
3091
|
+
post_body = @api_client.object_to_http_body(opts[:'data'])
|
3092
|
+
auth_names = ['apikey']
|
3093
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path,
|
3094
|
+
:header_params => header_params,
|
3095
|
+
:query_params => query_params,
|
3096
|
+
:form_params => form_params,
|
3097
|
+
:body => post_body,
|
3098
|
+
:auth_names => auth_names)
|
3099
|
+
if @api_client.config.debugging
|
3100
|
+
@api_client.config.logger.debug "API called: PackagesApi#packages_validate_upload_hex\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
3101
|
+
end
|
3102
|
+
return data, status_code, headers
|
3103
|
+
end
|
2919
3104
|
# Validate parameters for create LuaRocks package
|
2920
3105
|
# Validate parameters for create LuaRocks package
|
2921
3106
|
# @param owner
|
@@ -3465,6 +3650,67 @@ module CloudsmithApi
|
|
3465
3650
|
end
|
3466
3651
|
return data, status_code, headers
|
3467
3652
|
end
|
3653
|
+
# Validate parameters for create Swift package
|
3654
|
+
# Validate parameters for create Swift package
|
3655
|
+
# @param owner
|
3656
|
+
# @param repo
|
3657
|
+
# @param [Hash] opts the optional parameters
|
3658
|
+
# @option opts [SwiftPackageUploadRequest] :data
|
3659
|
+
# @return [nil]
|
3660
|
+
def packages_validate_upload_swift(owner, repo, opts = {})
|
3661
|
+
packages_validate_upload_swift_with_http_info(owner, repo, opts)
|
3662
|
+
nil
|
3663
|
+
end
|
3664
|
+
|
3665
|
+
# Validate parameters for create Swift package
|
3666
|
+
# Validate parameters for create Swift package
|
3667
|
+
# @param owner
|
3668
|
+
# @param repo
|
3669
|
+
# @param [Hash] opts the optional parameters
|
3670
|
+
# @option opts [SwiftPackageUploadRequest] :data
|
3671
|
+
# @return [Array<(nil, Fixnum, Hash)>] nil, response status code and response headers
|
3672
|
+
def packages_validate_upload_swift_with_http_info(owner, repo, opts = {})
|
3673
|
+
if @api_client.config.debugging
|
3674
|
+
@api_client.config.logger.debug 'Calling API: PackagesApi.packages_validate_upload_swift ...'
|
3675
|
+
end
|
3676
|
+
# verify the required parameter 'owner' is set
|
3677
|
+
if @api_client.config.client_side_validation && owner.nil?
|
3678
|
+
fail ArgumentError, "Missing the required parameter 'owner' when calling PackagesApi.packages_validate_upload_swift"
|
3679
|
+
end
|
3680
|
+
# verify the required parameter 'repo' is set
|
3681
|
+
if @api_client.config.client_side_validation && repo.nil?
|
3682
|
+
fail ArgumentError, "Missing the required parameter 'repo' when calling PackagesApi.packages_validate_upload_swift"
|
3683
|
+
end
|
3684
|
+
# resource path
|
3685
|
+
local_var_path = '/packages/{owner}/{repo}/validate-upload/swift/'.sub('{' + 'owner' + '}', owner.to_s).sub('{' + 'repo' + '}', repo.to_s)
|
3686
|
+
|
3687
|
+
# query parameters
|
3688
|
+
query_params = {}
|
3689
|
+
|
3690
|
+
# header parameters
|
3691
|
+
header_params = {}
|
3692
|
+
# HTTP header 'Accept' (if needed)
|
3693
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
3694
|
+
# HTTP header 'Content-Type'
|
3695
|
+
header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
|
3696
|
+
|
3697
|
+
# form parameters
|
3698
|
+
form_params = {}
|
3699
|
+
|
3700
|
+
# http body (model)
|
3701
|
+
post_body = @api_client.object_to_http_body(opts[:'data'])
|
3702
|
+
auth_names = ['apikey']
|
3703
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path,
|
3704
|
+
:header_params => header_params,
|
3705
|
+
:query_params => query_params,
|
3706
|
+
:form_params => form_params,
|
3707
|
+
:body => post_body,
|
3708
|
+
:auth_names => auth_names)
|
3709
|
+
if @api_client.config.debugging
|
3710
|
+
@api_client.config.logger.debug "API called: PackagesApi#packages_validate_upload_swift\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
3711
|
+
end
|
3712
|
+
return data, status_code, headers
|
3713
|
+
end
|
3468
3714
|
# Validate parameters for create Terraform package
|
3469
3715
|
# Validate parameters for create Terraform package
|
3470
3716
|
# @param owner
|
@@ -151,28 +151,28 @@ module CloudsmithApi
|
|
151
151
|
end
|
152
152
|
return data, status_code, headers
|
153
153
|
end
|
154
|
-
#
|
155
|
-
#
|
154
|
+
# Get a scan result.
|
155
|
+
# Get a scan result.
|
156
156
|
# @param owner
|
157
157
|
# @param repo
|
158
158
|
# @param package
|
159
|
-
# @param
|
159
|
+
# @param identifier
|
160
160
|
# @param [Hash] opts the optional parameters
|
161
161
|
# @return [VulnerabilityScanResults]
|
162
|
-
def vulnerabilities_read(owner, repo, package,
|
163
|
-
data, _status_code, _headers = vulnerabilities_read_with_http_info(owner, repo, package,
|
162
|
+
def vulnerabilities_read(owner, repo, package, identifier, opts = {})
|
163
|
+
data, _status_code, _headers = vulnerabilities_read_with_http_info(owner, repo, package, identifier, opts)
|
164
164
|
data
|
165
165
|
end
|
166
166
|
|
167
|
-
#
|
168
|
-
#
|
167
|
+
# Get a scan result.
|
168
|
+
# Get a scan result.
|
169
169
|
# @param owner
|
170
170
|
# @param repo
|
171
171
|
# @param package
|
172
|
-
# @param
|
172
|
+
# @param identifier
|
173
173
|
# @param [Hash] opts the optional parameters
|
174
174
|
# @return [Array<(VulnerabilityScanResults, Fixnum, Hash)>] VulnerabilityScanResults data, response status code and response headers
|
175
|
-
def vulnerabilities_read_with_http_info(owner, repo, package,
|
175
|
+
def vulnerabilities_read_with_http_info(owner, repo, package, identifier, opts = {})
|
176
176
|
if @api_client.config.debugging
|
177
177
|
@api_client.config.logger.debug 'Calling API: VulnerabilitiesApi.vulnerabilities_read ...'
|
178
178
|
end
|
@@ -188,12 +188,12 @@ module CloudsmithApi
|
|
188
188
|
if @api_client.config.client_side_validation && package.nil?
|
189
189
|
fail ArgumentError, "Missing the required parameter 'package' when calling VulnerabilitiesApi.vulnerabilities_read"
|
190
190
|
end
|
191
|
-
# verify the required parameter '
|
192
|
-
if @api_client.config.client_side_validation &&
|
193
|
-
fail ArgumentError, "Missing the required parameter '
|
191
|
+
# verify the required parameter 'identifier' is set
|
192
|
+
if @api_client.config.client_side_validation && identifier.nil?
|
193
|
+
fail ArgumentError, "Missing the required parameter 'identifier' when calling VulnerabilitiesApi.vulnerabilities_read"
|
194
194
|
end
|
195
195
|
# resource path
|
196
|
-
local_var_path = '/vulnerabilities/{owner}/{repo}/{package}/{
|
196
|
+
local_var_path = '/vulnerabilities/{owner}/{repo}/{package}/{identifier}/'.sub('{' + 'owner' + '}', owner.to_s).sub('{' + 'repo' + '}', repo.to_s).sub('{' + 'package' + '}', package.to_s).sub('{' + 'identifier' + '}', identifier.to_s)
|
197
197
|
|
198
198
|
# query parameters
|
199
199
|
query_params = {}
|
@@ -57,17 +57,12 @@ class Eula
|
|
57
57
|
# @return Array for valid properties with the reasons
|
58
58
|
def list_invalid_properties
|
59
59
|
invalid_properties = Array.new
|
60
|
-
if @number.nil?
|
61
|
-
invalid_properties.push('invalid value for "number", number cannot be nil.')
|
62
|
-
end
|
63
|
-
|
64
60
|
invalid_properties
|
65
61
|
end
|
66
62
|
|
67
63
|
# Check to see if the all the properties in the model are valid
|
68
64
|
# @return true if the model is valid
|
69
65
|
def valid?
|
70
|
-
return false if @number.nil?
|
71
66
|
true
|
72
67
|
end
|
73
68
|
|
@@ -17,6 +17,9 @@ class HelmPackageUploadRequest
|
|
17
17
|
# The primary file for the package.
|
18
18
|
attr_accessor :package_file
|
19
19
|
|
20
|
+
# The provenance file containing the signature for the chart. If one is not provided, it will be generated automatically.
|
21
|
+
attr_accessor :provenance_file
|
22
|
+
|
20
23
|
# If true, the uploaded package will overwrite any others with the same attributes (e.g. same version); otherwise, it will be flagged as a duplicate.
|
21
24
|
attr_accessor :republish
|
22
25
|
|
@@ -27,6 +30,7 @@ class HelmPackageUploadRequest
|
|
27
30
|
def self.attribute_map
|
28
31
|
{
|
29
32
|
:'package_file' => :'package_file',
|
33
|
+
:'provenance_file' => :'provenance_file',
|
30
34
|
:'republish' => :'republish',
|
31
35
|
:'tags' => :'tags'
|
32
36
|
}
|
@@ -36,6 +40,7 @@ class HelmPackageUploadRequest
|
|
36
40
|
def self.swagger_types
|
37
41
|
{
|
38
42
|
:'package_file' => :'String',
|
43
|
+
:'provenance_file' => :'String',
|
39
44
|
:'republish' => :'BOOLEAN',
|
40
45
|
:'tags' => :'String'
|
41
46
|
}
|
@@ -53,6 +58,10 @@ class HelmPackageUploadRequest
|
|
53
58
|
self.package_file = attributes[:'package_file']
|
54
59
|
end
|
55
60
|
|
61
|
+
if attributes.has_key?(:'provenance_file')
|
62
|
+
self.provenance_file = attributes[:'provenance_file']
|
63
|
+
end
|
64
|
+
|
56
65
|
if attributes.has_key?(:'republish')
|
57
66
|
self.republish = attributes[:'republish']
|
58
67
|
end
|
@@ -86,6 +95,7 @@ class HelmPackageUploadRequest
|
|
86
95
|
return true if self.equal?(o)
|
87
96
|
self.class == o.class &&
|
88
97
|
package_file == o.package_file &&
|
98
|
+
provenance_file == o.provenance_file &&
|
89
99
|
republish == o.republish &&
|
90
100
|
tags == o.tags
|
91
101
|
end
|
@@ -99,7 +109,7 @@ class HelmPackageUploadRequest
|
|
99
109
|
# Calculates hash code according to all attributes.
|
100
110
|
# @return [Fixnum] Hash code
|
101
111
|
def hash
|
102
|
-
[package_file, republish, tags].hash
|
112
|
+
[package_file, provenance_file, republish, tags].hash
|
103
113
|
end
|
104
114
|
|
105
115
|
# Builds the object from hash
|