dependency-tracker-client 1.0.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 +7 -0
- data/Gemfile +9 -0
- data/LICENSE +201 -0
- data/README.md +276 -0
- data/Rakefile +10 -0
- data/dependency-tracker-client.gemspec +39 -0
- data/docs/About.md +25 -0
- data/docs/Analysis.md +21 -0
- data/docs/AnalysisApi.md +177 -0
- data/docs/AnalysisComment.md +21 -0
- data/docs/AnalysisRequest.md +27 -0
- data/docs/ApiKey.md +17 -0
- data/docs/BadgeApi.md +102 -0
- data/docs/BodyPart.md +31 -0
- data/docs/BomApi.md +335 -0
- data/docs/BomSubmitRequest.md +25 -0
- data/docs/CalculatorApi.md +61 -0
- data/docs/CloneProjectRequest.md +19 -0
- data/docs/Component.md +69 -0
- data/docs/ComponentApi.md +373 -0
- data/docs/ComponentMetrics.md +43 -0
- data/docs/ConfigProperty.md +25 -0
- data/docs/ConfigPropertyApi.md +167 -0
- data/docs/ContentDisposition.md +29 -0
- data/docs/Cwe.md +19 -0
- data/docs/CweApi.md +110 -0
- data/docs/DefaultApi.md +434 -0
- data/docs/Dependency.md +27 -0
- data/docs/DependencyApi.md +222 -0
- data/docs/DependencyMetrics.md +45 -0
- data/docs/DependencyRequest.md +21 -0
- data/docs/Finding.md +23 -0
- data/docs/FindingApi.md +113 -0
- data/docs/FormDataBodyPart.md +39 -0
- data/docs/FormDataContentDisposition.md +31 -0
- data/docs/FormDataMultiPart.md +35 -0
- data/docs/Framework.md +23 -0
- data/docs/IdentifiableObject.md +17 -0
- data/docs/LdapApi.md +220 -0
- data/docs/LdapUser.md +25 -0
- data/docs/License.md +37 -0
- data/docs/LicenseApi.md +159 -0
- data/docs/ManagedUser.md +37 -0
- data/docs/MappedLdapGroup.md +19 -0
- data/docs/MappedLdapGroupRequest.md +19 -0
- data/docs/MediaType.md +25 -0
- data/docs/MetricsApi.md +922 -0
- data/docs/MultiPart.md +33 -0
- data/docs/NotificationPublisher.md +29 -0
- data/docs/NotificationRule.md +35 -0
- data/docs/PackageURL.md +29 -0
- data/docs/ParameterizedHeader.md +19 -0
- data/docs/Permission.md +19 -0
- data/docs/PermissionApi.md +279 -0
- data/docs/PortfolioMetrics.md +53 -0
- data/docs/Project.md +43 -0
- data/docs/ProjectApi.md +445 -0
- data/docs/ProjectMetrics.md +47 -0
- data/docs/ProjectProperty.md +27 -0
- data/docs/ProjectPropertyApi.md +232 -0
- data/docs/Repository.md +29 -0
- data/docs/RepositoryApi.md +325 -0
- data/docs/RepositoryMetaComponent.md +27 -0
- data/docs/Score.md +23 -0
- data/docs/SearchApi.md +120 -0
- data/docs/SearchResult.md +17 -0
- data/docs/Tag.md +19 -0
- data/docs/Team.md +29 -0
- data/docs/TeamApi.md +432 -0
- data/docs/UserApi.md +715 -0
- data/docs/UserPrincipal.md +27 -0
- data/docs/VersionApi.md +52 -0
- data/docs/Vulnerability.md +69 -0
- data/docs/VulnerabilityApi.md +666 -0
- data/docs/VulnerabilityMetrics.md +23 -0
- data/docs/VulnerableSoftware.md +69 -0
- data/lib/dependency-tracker-client/api/analysis_api.rb +209 -0
- data/lib/dependency-tracker-client/api/badge_api.rb +148 -0
- data/lib/dependency-tracker-client/api/bom_api.rb +382 -0
- data/lib/dependency-tracker-client/api/calculator_api.rb +83 -0
- data/lib/dependency-tracker-client/api/component_api.rb +422 -0
- data/lib/dependency-tracker-client/api/config_property_api.rb +192 -0
- data/lib/dependency-tracker-client/api/cwe_api.rb +136 -0
- data/lib/dependency-tracker-client/api/default_api.rb +491 -0
- data/lib/dependency-tracker-client/api/dependency_api.rb +254 -0
- data/lib/dependency-tracker-client/api/finding_api.rb +140 -0
- data/lib/dependency-tracker-client/api/ldap_api.rb +254 -0
- data/lib/dependency-tracker-client/api/license_api.rb +190 -0
- data/lib/dependency-tracker-client/api/metrics_api.rb +1086 -0
- data/lib/dependency-tracker-client/api/permission_api.rb +342 -0
- data/lib/dependency-tracker-client/api/project_api.rb +504 -0
- data/lib/dependency-tracker-client/api/project_property_api.rb +274 -0
- data/lib/dependency-tracker-client/api/repository_api.rb +376 -0
- data/lib/dependency-tracker-client/api/search_api.rb +143 -0
- data/lib/dependency-tracker-client/api/team_api.rb +486 -0
- data/lib/dependency-tracker-client/api/user_api.rb +796 -0
- data/lib/dependency-tracker-client/api/version_api.rb +78 -0
- data/lib/dependency-tracker-client/api/vulnerability_api.rb +780 -0
- data/lib/dependency-tracker-client/api_client.rb +388 -0
- data/lib/dependency-tracker-client/api_error.rb +57 -0
- data/lib/dependency-tracker-client/configuration.rb +261 -0
- data/lib/dependency-tracker-client/models/about.rb +242 -0
- data/lib/dependency-tracker-client/models/analysis.rb +265 -0
- data/lib/dependency-tracker-client/models/analysis_comment.rb +234 -0
- data/lib/dependency-tracker-client/models/analysis_request.rb +371 -0
- data/lib/dependency-tracker-client/models/api_key.rb +250 -0
- data/lib/dependency-tracker-client/models/body_part.rb +273 -0
- data/lib/dependency-tracker-client/models/bom_submit_request.rb +328 -0
- data/lib/dependency-tracker-client/models/clone_project_request.rb +267 -0
- data/lib/dependency-tracker-client/models/component.rb +900 -0
- data/lib/dependency-tracker-client/models/component_metrics.rb +338 -0
- data/lib/dependency-tracker-client/models/config_property.rb +421 -0
- data/lib/dependency-tracker-client/models/content_disposition.rb +262 -0
- data/lib/dependency-tracker-client/models/cwe.rb +259 -0
- data/lib/dependency-tracker-client/models/dependency.rb +266 -0
- data/lib/dependency-tracker-client/models/dependency_metrics.rb +352 -0
- data/lib/dependency-tracker-client/models/dependency_request.rb +257 -0
- data/lib/dependency-tracker-client/models/finding.rb +239 -0
- data/lib/dependency-tracker-client/models/form_data_body_part.rb +309 -0
- data/lib/dependency-tracker-client/models/form_data_content_disposition.rb +271 -0
- data/lib/dependency-tracker-client/models/form_data_multi_part.rb +295 -0
- data/lib/dependency-tracker-client/models/framework.rb +233 -0
- data/lib/dependency-tracker-client/models/identifiable_object.rb +206 -0
- data/lib/dependency-tracker-client/models/ldap_user.rb +351 -0
- data/lib/dependency-tracker-client/models/license.rb +373 -0
- data/lib/dependency-tracker-client/models/managed_user.rb +480 -0
- data/lib/dependency-tracker-client/models/mapped_ldap_group.rb +255 -0
- data/lib/dependency-tracker-client/models/mapped_ldap_group_request.rb +267 -0
- data/lib/dependency-tracker-client/models/media_type.rb +244 -0
- data/lib/dependency-tracker-client/models/multi_part.rb +284 -0
- data/lib/dependency-tracker-client/models/notification_publisher.rb +388 -0
- data/lib/dependency-tracker-client/models/notification_rule.rb +426 -0
- data/lib/dependency-tracker-client/models/package_url.rb +262 -0
- data/lib/dependency-tracker-client/models/parameterized_header.rb +217 -0
- data/lib/dependency-tracker-client/models/permission.rb +250 -0
- data/lib/dependency-tracker-client/models/portfolio_metrics.rb +378 -0
- data/lib/dependency-tracker-client/models/project.rb +420 -0
- data/lib/dependency-tracker-client/models/project_metrics.rb +356 -0
- data/lib/dependency-tracker-client/models/project_property.rb +430 -0
- data/lib/dependency-tracker-client/models/repository.rb +319 -0
- data/lib/dependency-tracker-client/models/repository_meta_component.rb +305 -0
- data/lib/dependency-tracker-client/models/score.rb +233 -0
- data/lib/dependency-tracker-client/models/search_result.rb +208 -0
- data/lib/dependency-tracker-client/models/tag.rb +252 -0
- data/lib/dependency-tracker-client/models/team.rb +310 -0
- data/lib/dependency-tracker-client/models/user_principal.rb +255 -0
- data/lib/dependency-tracker-client/models/vulnerability.rb +729 -0
- data/lib/dependency-tracker-client/models/vulnerability_metrics.rb +238 -0
- data/lib/dependency-tracker-client/models/vulnerable_software.rb +442 -0
- data/lib/dependency-tracker-client/version.rb +15 -0
- data/lib/dependency-tracker-client.rb +109 -0
- data/pkg/dependency-tracker-client-1.0.0.gem +0 -0
- data/spec/api/analysis_api_spec.rb +70 -0
- data/spec/api/badge_api_spec.rb +58 -0
- data/spec/api/bom_api_spec.rb +106 -0
- data/spec/api/calculator_api_spec.rb +46 -0
- data/spec/api/component_api_spec.rb +110 -0
- data/spec/api/config_property_api_spec.rb +67 -0
- data/spec/api/cwe_api_spec.rb +56 -0
- data/spec/api/default_api_spec.rb +123 -0
- data/spec/api/dependency_api_spec.rb +79 -0
- data/spec/api/finding_api_spec.rb +57 -0
- data/spec/api/ldap_api_spec.rb +79 -0
- data/spec/api/license_api_spec.rb +66 -0
- data/spec/api/metrics_api_spec.rb +233 -0
- data/spec/api/permission_api_spec.rb +94 -0
- data/spec/api/project_api_spec.rb +126 -0
- data/spec/api/project_property_api_spec.rb +82 -0
- data/spec/api/repository_api_spec.rb +100 -0
- data/spec/api/search_api_spec.rb +59 -0
- data/spec/api/team_api_spec.rb +122 -0
- data/spec/api/user_api_spec.rb +183 -0
- data/spec/api/version_api_spec.rb +46 -0
- data/spec/api/vulnerability_api_spec.rb +177 -0
- data/spec/api_client_spec.rb +226 -0
- data/spec/configuration_spec.rb +42 -0
- data/spec/models/about_spec.rb +65 -0
- data/spec/models/analysis_comment_spec.rb +53 -0
- data/spec/models/analysis_request_spec.rb +75 -0
- data/spec/models/analysis_spec.rb +57 -0
- data/spec/models/api_key_spec.rb +41 -0
- data/spec/models/body_part_spec.rb +83 -0
- data/spec/models/bom_submit_request_spec.rb +65 -0
- data/spec/models/clone_project_request_spec.rb +47 -0
- data/spec/models/component_metrics_spec.rb +119 -0
- data/spec/models/component_spec.rb +201 -0
- data/spec/models/config_property_spec.rb +69 -0
- data/spec/models/content_disposition_spec.rb +77 -0
- data/spec/models/cwe_spec.rb +47 -0
- data/spec/models/dependency_metrics_spec.rb +125 -0
- data/spec/models/dependency_request_spec.rb +53 -0
- data/spec/models/dependency_spec.rb +71 -0
- data/spec/models/finding_spec.rb +59 -0
- data/spec/models/form_data_body_part_spec.rb +107 -0
- data/spec/models/form_data_content_disposition_spec.rb +83 -0
- data/spec/models/form_data_multi_part_spec.rb +95 -0
- data/spec/models/framework_spec.rb +59 -0
- data/spec/models/identifiable_object_spec.rb +41 -0
- data/spec/models/ldap_user_spec.rb +65 -0
- data/spec/models/license_spec.rb +101 -0
- data/spec/models/managed_user_spec.rb +101 -0
- data/spec/models/mapped_ldap_group_request_spec.rb +47 -0
- data/spec/models/mapped_ldap_group_spec.rb +47 -0
- data/spec/models/media_type_spec.rb +65 -0
- data/spec/models/multi_part_spec.rb +89 -0
- data/spec/models/notification_publisher_spec.rb +77 -0
- data/spec/models/notification_rule_spec.rb +107 -0
- data/spec/models/package_url_spec.rb +77 -0
- data/spec/models/parameterized_header_spec.rb +47 -0
- data/spec/models/permission_spec.rb +47 -0
- data/spec/models/portfolio_metrics_spec.rb +149 -0
- data/spec/models/project_metrics_spec.rb +131 -0
- data/spec/models/project_property_spec.rb +75 -0
- data/spec/models/project_spec.rb +119 -0
- data/spec/models/repository_meta_component_spec.rb +75 -0
- data/spec/models/repository_spec.rb +81 -0
- data/spec/models/score_spec.rb +59 -0
- data/spec/models/search_result_spec.rb +41 -0
- data/spec/models/tag_spec.rb +47 -0
- data/spec/models/team_spec.rb +77 -0
- data/spec/models/user_principal_spec.rb +71 -0
- data/spec/models/vulnerability_metrics_spec.rb +59 -0
- data/spec/models/vulnerability_spec.rb +201 -0
- data/spec/models/vulnerable_software_spec.rb +197 -0
- data/spec/spec_helper.rb +111 -0
- data/tmp/tmp.rb +11 -0
- metadata +402 -0
@@ -0,0 +1,25 @@
|
|
1
|
+
# DependencyTracker::BomSubmitRequest
|
2
|
+
|
3
|
+
## Properties
|
4
|
+
|
5
|
+
Name | Type | Description | Notes
|
6
|
+
------------ | ------------- | ------------- | -------------
|
7
|
+
**project** | **String** | | [readonly]
|
8
|
+
**project_name** | **String** | | [optional] [readonly]
|
9
|
+
**project_version** | **String** | | [optional] [readonly]
|
10
|
+
**auto_create** | **Boolean** | | [optional] [readonly]
|
11
|
+
**bom** | **String** | | [readonly]
|
12
|
+
|
13
|
+
## Code Sample
|
14
|
+
|
15
|
+
```ruby
|
16
|
+
require 'DependencyTracker'
|
17
|
+
|
18
|
+
instance = DependencyTracker::BomSubmitRequest.new(project: null,
|
19
|
+
project_name: null,
|
20
|
+
project_version: null,
|
21
|
+
auto_create: null,
|
22
|
+
bom: null)
|
23
|
+
```
|
24
|
+
|
25
|
+
|
@@ -0,0 +1,61 @@
|
|
1
|
+
# DependencyTracker::CalculatorApi
|
2
|
+
|
3
|
+
All URIs are relative to *http://localhost/api*
|
4
|
+
|
5
|
+
Method | HTTP request | Description
|
6
|
+
------------- | ------------- | -------------
|
7
|
+
[**get_cvss_scores**](CalculatorApi.md#get_cvss_scores) | **GET** /v1/calculator/cvss | Returns the CVSS base score, impact sub-score and exploitability sub-score
|
8
|
+
|
9
|
+
|
10
|
+
|
11
|
+
## get_cvss_scores
|
12
|
+
|
13
|
+
> Score get_cvss_scores(vector)
|
14
|
+
|
15
|
+
Returns the CVSS base score, impact sub-score and exploitability sub-score
|
16
|
+
|
17
|
+
### Example
|
18
|
+
|
19
|
+
```ruby
|
20
|
+
# load the gem
|
21
|
+
require 'dependency-tracker-client'
|
22
|
+
# setup authorization
|
23
|
+
DependencyTracker.configure do |config|
|
24
|
+
# Configure API key authorization: X-Api-Key
|
25
|
+
config.api_key['X-Api-Key'] = 'YOUR API KEY'
|
26
|
+
# Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
|
27
|
+
#config.api_key_prefix['X-Api-Key'] = 'Bearer'
|
28
|
+
end
|
29
|
+
|
30
|
+
api_instance = DependencyTracker::CalculatorApi.new
|
31
|
+
vector = 'vector_example' # String | A valid CVSSv2 or CVSSv3 vector
|
32
|
+
|
33
|
+
begin
|
34
|
+
#Returns the CVSS base score, impact sub-score and exploitability sub-score
|
35
|
+
result = api_instance.get_cvss_scores(vector)
|
36
|
+
p result
|
37
|
+
rescue DependencyTracker::ApiError => e
|
38
|
+
puts "Exception when calling CalculatorApi->get_cvss_scores: #{e}"
|
39
|
+
end
|
40
|
+
```
|
41
|
+
|
42
|
+
### Parameters
|
43
|
+
|
44
|
+
|
45
|
+
Name | Type | Description | Notes
|
46
|
+
------------- | ------------- | ------------- | -------------
|
47
|
+
**vector** | **String**| A valid CVSSv2 or CVSSv3 vector |
|
48
|
+
|
49
|
+
### Return type
|
50
|
+
|
51
|
+
[**Score**](Score.md)
|
52
|
+
|
53
|
+
### Authorization
|
54
|
+
|
55
|
+
[X-Api-Key](../README.md#X-Api-Key)
|
56
|
+
|
57
|
+
### HTTP request headers
|
58
|
+
|
59
|
+
- **Content-Type**: Not defined
|
60
|
+
- **Accept**: application/json
|
61
|
+
|
@@ -0,0 +1,19 @@
|
|
1
|
+
# DependencyTracker::CloneProjectRequest
|
2
|
+
|
3
|
+
## Properties
|
4
|
+
|
5
|
+
Name | Type | Description | Notes
|
6
|
+
------------ | ------------- | ------------- | -------------
|
7
|
+
**project** | **String** | | [readonly]
|
8
|
+
**version** | **String** | | [readonly]
|
9
|
+
|
10
|
+
## Code Sample
|
11
|
+
|
12
|
+
```ruby
|
13
|
+
require 'DependencyTracker'
|
14
|
+
|
15
|
+
instance = DependencyTracker::CloneProjectRequest.new(project: null,
|
16
|
+
version: null)
|
17
|
+
```
|
18
|
+
|
19
|
+
|
data/docs/Component.md
ADDED
@@ -0,0 +1,69 @@
|
|
1
|
+
# DependencyTracker::Component
|
2
|
+
|
3
|
+
## Properties
|
4
|
+
|
5
|
+
Name | Type | Description | Notes
|
6
|
+
------------ | ------------- | ------------- | -------------
|
7
|
+
**group** | **String** | | [optional]
|
8
|
+
**name** | **String** | | [optional]
|
9
|
+
**version** | **String** | | [optional]
|
10
|
+
**classifier** | **String** | | [optional]
|
11
|
+
**filename** | **String** | | [optional]
|
12
|
+
**extension** | **String** | | [optional]
|
13
|
+
**md5** | **String** | | [optional]
|
14
|
+
**sha1** | **String** | | [optional]
|
15
|
+
**sha256** | **String** | | [optional]
|
16
|
+
**sha512** | **String** | | [optional]
|
17
|
+
**sha3_256** | **String** | | [optional]
|
18
|
+
**sha3_512** | **String** | | [optional]
|
19
|
+
**cpe** | **String** | | [optional]
|
20
|
+
**purl** | [**PackageURL**](PackageURL.md) | | [optional]
|
21
|
+
**description** | **String** | | [optional]
|
22
|
+
**copyright** | **String** | | [optional]
|
23
|
+
**license** | **String** | | [optional]
|
24
|
+
**resolved_license** | [**License**](License.md) | | [optional]
|
25
|
+
**parent** | [**Component**](Component.md) | | [optional]
|
26
|
+
**children** | [**Array<Component>**](Component.md) | | [optional]
|
27
|
+
**vulnerabilities** | [**Array<Vulnerability>**](Vulnerability.md) | | [optional]
|
28
|
+
**last_inherited_risk_score** | **Float** | | [optional]
|
29
|
+
**uuid** | **String** | |
|
30
|
+
**metrics** | [**ComponentMetrics**](ComponentMetrics.md) | | [optional]
|
31
|
+
**repository_meta** | [**RepositoryMetaComponent**](RepositoryMetaComponent.md) | | [optional]
|
32
|
+
**used_by** | **Integer** | | [optional]
|
33
|
+
**is_internal** | **Boolean** | | [optional]
|
34
|
+
|
35
|
+
## Code Sample
|
36
|
+
|
37
|
+
```ruby
|
38
|
+
require 'DependencyTracker'
|
39
|
+
|
40
|
+
instance = DependencyTracker::Component.new(group: null,
|
41
|
+
name: null,
|
42
|
+
version: null,
|
43
|
+
classifier: null,
|
44
|
+
filename: null,
|
45
|
+
extension: null,
|
46
|
+
md5: null,
|
47
|
+
sha1: null,
|
48
|
+
sha256: null,
|
49
|
+
sha512: null,
|
50
|
+
sha3_256: null,
|
51
|
+
sha3_512: null,
|
52
|
+
cpe: null,
|
53
|
+
purl: null,
|
54
|
+
description: null,
|
55
|
+
copyright: null,
|
56
|
+
license: null,
|
57
|
+
resolved_license: null,
|
58
|
+
parent: null,
|
59
|
+
children: null,
|
60
|
+
vulnerabilities: null,
|
61
|
+
last_inherited_risk_score: null,
|
62
|
+
uuid: null,
|
63
|
+
metrics: null,
|
64
|
+
repository_meta: null,
|
65
|
+
used_by: null,
|
66
|
+
is_internal: null)
|
67
|
+
```
|
68
|
+
|
69
|
+
|
@@ -0,0 +1,373 @@
|
|
1
|
+
# DependencyTracker::ComponentApi
|
2
|
+
|
3
|
+
All URIs are relative to *http://localhost/api*
|
4
|
+
|
5
|
+
Method | HTTP request | Description
|
6
|
+
------------- | ------------- | -------------
|
7
|
+
[**create_component**](ComponentApi.md#create_component) | **PUT** /v1/component | Creates a new component
|
8
|
+
[**delete_component**](ComponentApi.md#delete_component) | **DELETE** /v1/component/{uuid} | Deletes a component
|
9
|
+
[**get_all_components**](ComponentApi.md#get_all_components) | **GET** /v1/component | Returns a list of all components
|
10
|
+
[**get_component_by_hash**](ComponentApi.md#get_component_by_hash) | **GET** /v1/component/hash/{hash} | Returns a specific component
|
11
|
+
[**get_component_by_uuid**](ComponentApi.md#get_component_by_uuid) | **GET** /v1/component/{uuid} | Returns a specific component
|
12
|
+
[**identify_internal_components**](ComponentApi.md#identify_internal_components) | **GET** /v1/component/internal/identify | Requests the identification of internal components in the portfolio
|
13
|
+
[**update_component**](ComponentApi.md#update_component) | **POST** /v1/component | Updates a component
|
14
|
+
|
15
|
+
|
16
|
+
|
17
|
+
## create_component
|
18
|
+
|
19
|
+
> Component create_component(opts)
|
20
|
+
|
21
|
+
Creates a new component
|
22
|
+
|
23
|
+
### Example
|
24
|
+
|
25
|
+
```ruby
|
26
|
+
# load the gem
|
27
|
+
require 'dependency-tracker-client'
|
28
|
+
# setup authorization
|
29
|
+
DependencyTracker.configure do |config|
|
30
|
+
# Configure API key authorization: X-Api-Key
|
31
|
+
config.api_key['X-Api-Key'] = 'YOUR API KEY'
|
32
|
+
# Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
|
33
|
+
#config.api_key_prefix['X-Api-Key'] = 'Bearer'
|
34
|
+
end
|
35
|
+
|
36
|
+
api_instance = DependencyTracker::ComponentApi.new
|
37
|
+
opts = {
|
38
|
+
body: DependencyTracker::Component.new # Component |
|
39
|
+
}
|
40
|
+
|
41
|
+
begin
|
42
|
+
#Creates a new component
|
43
|
+
result = api_instance.create_component(opts)
|
44
|
+
p result
|
45
|
+
rescue DependencyTracker::ApiError => e
|
46
|
+
puts "Exception when calling ComponentApi->create_component: #{e}"
|
47
|
+
end
|
48
|
+
```
|
49
|
+
|
50
|
+
### Parameters
|
51
|
+
|
52
|
+
|
53
|
+
Name | Type | Description | Notes
|
54
|
+
------------- | ------------- | ------------- | -------------
|
55
|
+
**body** | [**Component**](Component.md)| | [optional]
|
56
|
+
|
57
|
+
### Return type
|
58
|
+
|
59
|
+
[**Component**](Component.md)
|
60
|
+
|
61
|
+
### Authorization
|
62
|
+
|
63
|
+
[X-Api-Key](../README.md#X-Api-Key)
|
64
|
+
|
65
|
+
### HTTP request headers
|
66
|
+
|
67
|
+
- **Content-Type**: application/json
|
68
|
+
- **Accept**: application/json
|
69
|
+
|
70
|
+
|
71
|
+
## delete_component
|
72
|
+
|
73
|
+
> delete_component(uuid)
|
74
|
+
|
75
|
+
Deletes a component
|
76
|
+
|
77
|
+
### Example
|
78
|
+
|
79
|
+
```ruby
|
80
|
+
# load the gem
|
81
|
+
require 'dependency-tracker-client'
|
82
|
+
# setup authorization
|
83
|
+
DependencyTracker.configure do |config|
|
84
|
+
# Configure API key authorization: X-Api-Key
|
85
|
+
config.api_key['X-Api-Key'] = 'YOUR API KEY'
|
86
|
+
# Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
|
87
|
+
#config.api_key_prefix['X-Api-Key'] = 'Bearer'
|
88
|
+
end
|
89
|
+
|
90
|
+
api_instance = DependencyTracker::ComponentApi.new
|
91
|
+
uuid = 'uuid_example' # String | The UUID of the component to delete
|
92
|
+
|
93
|
+
begin
|
94
|
+
#Deletes a component
|
95
|
+
api_instance.delete_component(uuid)
|
96
|
+
rescue DependencyTracker::ApiError => e
|
97
|
+
puts "Exception when calling ComponentApi->delete_component: #{e}"
|
98
|
+
end
|
99
|
+
```
|
100
|
+
|
101
|
+
### Parameters
|
102
|
+
|
103
|
+
|
104
|
+
Name | Type | Description | Notes
|
105
|
+
------------- | ------------- | ------------- | -------------
|
106
|
+
**uuid** | **String**| The UUID of the component to delete |
|
107
|
+
|
108
|
+
### Return type
|
109
|
+
|
110
|
+
nil (empty response body)
|
111
|
+
|
112
|
+
### Authorization
|
113
|
+
|
114
|
+
[X-Api-Key](../README.md#X-Api-Key)
|
115
|
+
|
116
|
+
### HTTP request headers
|
117
|
+
|
118
|
+
- **Content-Type**: Not defined
|
119
|
+
- **Accept**: Not defined
|
120
|
+
|
121
|
+
|
122
|
+
## get_all_components
|
123
|
+
|
124
|
+
> Array<Component> get_all_components
|
125
|
+
|
126
|
+
Returns a list of all components
|
127
|
+
|
128
|
+
### Example
|
129
|
+
|
130
|
+
```ruby
|
131
|
+
# load the gem
|
132
|
+
require 'dependency-tracker-client'
|
133
|
+
# setup authorization
|
134
|
+
DependencyTracker.configure do |config|
|
135
|
+
# Configure API key authorization: X-Api-Key
|
136
|
+
config.api_key['X-Api-Key'] = 'YOUR API KEY'
|
137
|
+
# Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
|
138
|
+
#config.api_key_prefix['X-Api-Key'] = 'Bearer'
|
139
|
+
end
|
140
|
+
|
141
|
+
api_instance = DependencyTracker::ComponentApi.new
|
142
|
+
|
143
|
+
begin
|
144
|
+
#Returns a list of all components
|
145
|
+
result = api_instance.get_all_components
|
146
|
+
p result
|
147
|
+
rescue DependencyTracker::ApiError => e
|
148
|
+
puts "Exception when calling ComponentApi->get_all_components: #{e}"
|
149
|
+
end
|
150
|
+
```
|
151
|
+
|
152
|
+
### Parameters
|
153
|
+
|
154
|
+
This endpoint does not need any parameter.
|
155
|
+
|
156
|
+
### Return type
|
157
|
+
|
158
|
+
[**Array<Component>**](Component.md)
|
159
|
+
|
160
|
+
### Authorization
|
161
|
+
|
162
|
+
[X-Api-Key](../README.md#X-Api-Key)
|
163
|
+
|
164
|
+
### HTTP request headers
|
165
|
+
|
166
|
+
- **Content-Type**: Not defined
|
167
|
+
- **Accept**: application/json
|
168
|
+
|
169
|
+
|
170
|
+
## get_component_by_hash
|
171
|
+
|
172
|
+
> Component get_component_by_hash(hash)
|
173
|
+
|
174
|
+
Returns a specific component
|
175
|
+
|
176
|
+
### Example
|
177
|
+
|
178
|
+
```ruby
|
179
|
+
# load the gem
|
180
|
+
require 'dependency-tracker-client'
|
181
|
+
# setup authorization
|
182
|
+
DependencyTracker.configure do |config|
|
183
|
+
# Configure API key authorization: X-Api-Key
|
184
|
+
config.api_key['X-Api-Key'] = 'YOUR API KEY'
|
185
|
+
# Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
|
186
|
+
#config.api_key_prefix['X-Api-Key'] = 'Bearer'
|
187
|
+
end
|
188
|
+
|
189
|
+
api_instance = DependencyTracker::ComponentApi.new
|
190
|
+
hash = 'hash_example' # String | The MD5, SHA-1, SHA-256, SHA-512, SHA3-256, or SHA3-512 hash of the component to retrieve
|
191
|
+
|
192
|
+
begin
|
193
|
+
#Returns a specific component
|
194
|
+
result = api_instance.get_component_by_hash(hash)
|
195
|
+
p result
|
196
|
+
rescue DependencyTracker::ApiError => e
|
197
|
+
puts "Exception when calling ComponentApi->get_component_by_hash: #{e}"
|
198
|
+
end
|
199
|
+
```
|
200
|
+
|
201
|
+
### Parameters
|
202
|
+
|
203
|
+
|
204
|
+
Name | Type | Description | Notes
|
205
|
+
------------- | ------------- | ------------- | -------------
|
206
|
+
**hash** | **String**| The MD5, SHA-1, SHA-256, SHA-512, SHA3-256, or SHA3-512 hash of the component to retrieve |
|
207
|
+
|
208
|
+
### Return type
|
209
|
+
|
210
|
+
[**Component**](Component.md)
|
211
|
+
|
212
|
+
### Authorization
|
213
|
+
|
214
|
+
[X-Api-Key](../README.md#X-Api-Key)
|
215
|
+
|
216
|
+
### HTTP request headers
|
217
|
+
|
218
|
+
- **Content-Type**: Not defined
|
219
|
+
- **Accept**: application/json
|
220
|
+
|
221
|
+
|
222
|
+
## get_component_by_uuid
|
223
|
+
|
224
|
+
> Component get_component_by_uuid(uuid)
|
225
|
+
|
226
|
+
Returns a specific component
|
227
|
+
|
228
|
+
### Example
|
229
|
+
|
230
|
+
```ruby
|
231
|
+
# load the gem
|
232
|
+
require 'dependency-tracker-client'
|
233
|
+
# setup authorization
|
234
|
+
DependencyTracker.configure do |config|
|
235
|
+
# Configure API key authorization: X-Api-Key
|
236
|
+
config.api_key['X-Api-Key'] = 'YOUR API KEY'
|
237
|
+
# Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
|
238
|
+
#config.api_key_prefix['X-Api-Key'] = 'Bearer'
|
239
|
+
end
|
240
|
+
|
241
|
+
api_instance = DependencyTracker::ComponentApi.new
|
242
|
+
uuid = 'uuid_example' # String | The UUID of the component to retrieve
|
243
|
+
|
244
|
+
begin
|
245
|
+
#Returns a specific component
|
246
|
+
result = api_instance.get_component_by_uuid(uuid)
|
247
|
+
p result
|
248
|
+
rescue DependencyTracker::ApiError => e
|
249
|
+
puts "Exception when calling ComponentApi->get_component_by_uuid: #{e}"
|
250
|
+
end
|
251
|
+
```
|
252
|
+
|
253
|
+
### Parameters
|
254
|
+
|
255
|
+
|
256
|
+
Name | Type | Description | Notes
|
257
|
+
------------- | ------------- | ------------- | -------------
|
258
|
+
**uuid** | **String**| The UUID of the component to retrieve |
|
259
|
+
|
260
|
+
### Return type
|
261
|
+
|
262
|
+
[**Component**](Component.md)
|
263
|
+
|
264
|
+
### Authorization
|
265
|
+
|
266
|
+
[X-Api-Key](../README.md#X-Api-Key)
|
267
|
+
|
268
|
+
### HTTP request headers
|
269
|
+
|
270
|
+
- **Content-Type**: Not defined
|
271
|
+
- **Accept**: application/json
|
272
|
+
|
273
|
+
|
274
|
+
## identify_internal_components
|
275
|
+
|
276
|
+
> identify_internal_components
|
277
|
+
|
278
|
+
Requests the identification of internal components in the portfolio
|
279
|
+
|
280
|
+
### Example
|
281
|
+
|
282
|
+
```ruby
|
283
|
+
# load the gem
|
284
|
+
require 'dependency-tracker-client'
|
285
|
+
# setup authorization
|
286
|
+
DependencyTracker.configure do |config|
|
287
|
+
# Configure API key authorization: X-Api-Key
|
288
|
+
config.api_key['X-Api-Key'] = 'YOUR API KEY'
|
289
|
+
# Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
|
290
|
+
#config.api_key_prefix['X-Api-Key'] = 'Bearer'
|
291
|
+
end
|
292
|
+
|
293
|
+
api_instance = DependencyTracker::ComponentApi.new
|
294
|
+
|
295
|
+
begin
|
296
|
+
#Requests the identification of internal components in the portfolio
|
297
|
+
api_instance.identify_internal_components
|
298
|
+
rescue DependencyTracker::ApiError => e
|
299
|
+
puts "Exception when calling ComponentApi->identify_internal_components: #{e}"
|
300
|
+
end
|
301
|
+
```
|
302
|
+
|
303
|
+
### Parameters
|
304
|
+
|
305
|
+
This endpoint does not need any parameter.
|
306
|
+
|
307
|
+
### Return type
|
308
|
+
|
309
|
+
nil (empty response body)
|
310
|
+
|
311
|
+
### Authorization
|
312
|
+
|
313
|
+
[X-Api-Key](../README.md#X-Api-Key)
|
314
|
+
|
315
|
+
### HTTP request headers
|
316
|
+
|
317
|
+
- **Content-Type**: Not defined
|
318
|
+
- **Accept**: Not defined
|
319
|
+
|
320
|
+
|
321
|
+
## update_component
|
322
|
+
|
323
|
+
> Component update_component(opts)
|
324
|
+
|
325
|
+
Updates a component
|
326
|
+
|
327
|
+
### Example
|
328
|
+
|
329
|
+
```ruby
|
330
|
+
# load the gem
|
331
|
+
require 'dependency-tracker-client'
|
332
|
+
# setup authorization
|
333
|
+
DependencyTracker.configure do |config|
|
334
|
+
# Configure API key authorization: X-Api-Key
|
335
|
+
config.api_key['X-Api-Key'] = 'YOUR API KEY'
|
336
|
+
# Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
|
337
|
+
#config.api_key_prefix['X-Api-Key'] = 'Bearer'
|
338
|
+
end
|
339
|
+
|
340
|
+
api_instance = DependencyTracker::ComponentApi.new
|
341
|
+
opts = {
|
342
|
+
body: DependencyTracker::Component.new # Component |
|
343
|
+
}
|
344
|
+
|
345
|
+
begin
|
346
|
+
#Updates a component
|
347
|
+
result = api_instance.update_component(opts)
|
348
|
+
p result
|
349
|
+
rescue DependencyTracker::ApiError => e
|
350
|
+
puts "Exception when calling ComponentApi->update_component: #{e}"
|
351
|
+
end
|
352
|
+
```
|
353
|
+
|
354
|
+
### Parameters
|
355
|
+
|
356
|
+
|
357
|
+
Name | Type | Description | Notes
|
358
|
+
------------- | ------------- | ------------- | -------------
|
359
|
+
**body** | [**Component**](Component.md)| | [optional]
|
360
|
+
|
361
|
+
### Return type
|
362
|
+
|
363
|
+
[**Component**](Component.md)
|
364
|
+
|
365
|
+
### Authorization
|
366
|
+
|
367
|
+
[X-Api-Key](../README.md#X-Api-Key)
|
368
|
+
|
369
|
+
### HTTP request headers
|
370
|
+
|
371
|
+
- **Content-Type**: application/json
|
372
|
+
- **Accept**: application/json
|
373
|
+
|
@@ -0,0 +1,43 @@
|
|
1
|
+
# DependencyTracker::ComponentMetrics
|
2
|
+
|
3
|
+
## Properties
|
4
|
+
|
5
|
+
Name | Type | Description | Notes
|
6
|
+
------------ | ------------- | ------------- | -------------
|
7
|
+
**component** | [**Component**](Component.md) | |
|
8
|
+
**critical** | **Integer** | | [optional]
|
9
|
+
**high** | **Integer** | | [optional]
|
10
|
+
**medium** | **Integer** | | [optional]
|
11
|
+
**low** | **Integer** | | [optional]
|
12
|
+
**unassigned** | **Integer** | | [optional]
|
13
|
+
**vulnerabilities** | **Integer** | | [optional]
|
14
|
+
**suppressed** | **Integer** | | [optional]
|
15
|
+
**findings_total** | **Integer** | | [optional]
|
16
|
+
**findings_audited** | **Integer** | | [optional]
|
17
|
+
**findings_unaudited** | **Integer** | | [optional]
|
18
|
+
**inherited_risk_score** | **Float** | | [optional]
|
19
|
+
**first_occurrence** | **Integer** | |
|
20
|
+
**last_occurrence** | **Integer** | |
|
21
|
+
|
22
|
+
## Code Sample
|
23
|
+
|
24
|
+
```ruby
|
25
|
+
require 'DependencyTracker'
|
26
|
+
|
27
|
+
instance = DependencyTracker::ComponentMetrics.new(component: null,
|
28
|
+
critical: null,
|
29
|
+
high: null,
|
30
|
+
medium: null,
|
31
|
+
low: null,
|
32
|
+
unassigned: null,
|
33
|
+
vulnerabilities: null,
|
34
|
+
suppressed: null,
|
35
|
+
findings_total: null,
|
36
|
+
findings_audited: null,
|
37
|
+
findings_unaudited: null,
|
38
|
+
inherited_risk_score: null,
|
39
|
+
first_occurrence: null,
|
40
|
+
last_occurrence: null)
|
41
|
+
```
|
42
|
+
|
43
|
+
|
@@ -0,0 +1,25 @@
|
|
1
|
+
# DependencyTracker::ConfigProperty
|
2
|
+
|
3
|
+
## Properties
|
4
|
+
|
5
|
+
Name | Type | Description | Notes
|
6
|
+
------------ | ------------- | ------------- | -------------
|
7
|
+
**group_name** | **String** | | [optional]
|
8
|
+
**property_name** | **String** | | [optional]
|
9
|
+
**property_value** | **String** | | [optional]
|
10
|
+
**property_type** | **String** | |
|
11
|
+
**description** | **String** | | [optional]
|
12
|
+
|
13
|
+
## Code Sample
|
14
|
+
|
15
|
+
```ruby
|
16
|
+
require 'DependencyTracker'
|
17
|
+
|
18
|
+
instance = DependencyTracker::ConfigProperty.new(group_name: null,
|
19
|
+
property_name: null,
|
20
|
+
property_value: null,
|
21
|
+
property_type: null,
|
22
|
+
description: null)
|
23
|
+
```
|
24
|
+
|
25
|
+
|