Documentation
¶
Overview ¶
* Harbor API * * These APIs provide services for manipulating Harbor project. * * API version: 2.0 * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
* Harbor API * * These APIs provide services for manipulating Harbor project. * * API version: 2.0 * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
* Harbor API * * These APIs provide services for manipulating Harbor project. * * API version: 2.0 * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
* Harbor API * * These APIs provide services for manipulating Harbor project. * * API version: 2.0 * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
* Harbor API * * These APIs provide services for manipulating Harbor project. * * API version: 2.0 * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
* Harbor API * * These APIs provide services for manipulating Harbor project. * * API version: 2.0 * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
* Harbor API * * These APIs provide services for manipulating Harbor project. * * API version: 2.0 * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
* Harbor API * * These APIs provide services for manipulating Harbor project. * * API version: 2.0 * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
* Harbor API * * These APIs provide services for manipulating Harbor project. * * API version: 2.0 * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
* Harbor API * * These APIs provide services for manipulating Harbor project. * * API version: 2.0 * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
* Harbor API * * These APIs provide services for manipulating Harbor project. * * API version: 2.0 * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
* Harbor API * * These APIs provide services for manipulating Harbor project. * * API version: 2.0 * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
* Harbor API * * These APIs provide services for manipulating Harbor project. * * API version: 2.0 * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
* Harbor API * * These APIs provide services for manipulating Harbor project. * * API version: 2.0 * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
* Harbor API * * These APIs provide services for manipulating Harbor project. * * API version: 2.0 * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
* Harbor API * * These APIs provide services for manipulating Harbor project. * * API version: 2.0 * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
* Harbor API * * These APIs provide services for manipulating Harbor project. * * API version: 2.0 * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
* Harbor API * * These APIs provide services for manipulating Harbor project. * * API version: 2.0 * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
* Harbor API * * These APIs provide services for manipulating Harbor project. * * API version: 2.0 * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
* Harbor API * * These APIs provide services for manipulating Harbor project. * * API version: 2.0 * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
* Harbor API * * These APIs provide services for manipulating Harbor project. * * API version: 2.0 * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
* Harbor API * * These APIs provide services for manipulating Harbor project. * * API version: 2.0 * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
* Harbor API * * These APIs provide services for manipulating Harbor project. * * API version: 2.0 * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
* Harbor API * * These APIs provide services for manipulating Harbor project. * * API version: 2.0 * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
* Harbor API * * These APIs provide services for manipulating Harbor project. * * API version: 2.0 * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
* Harbor API * * These APIs provide services for manipulating Harbor project. * * API version: 2.0 * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
* Harbor API * * These APIs provide services for manipulating Harbor project. * * API version: 2.0 * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
* Harbor API * * These APIs provide services for manipulating Harbor project. * * API version: 2.0 * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
* Harbor API * * These APIs provide services for manipulating Harbor project. * * API version: 2.0 * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
* Harbor API * * These APIs provide services for manipulating Harbor project. * * API version: 2.0 * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
Index ¶
- Variables
- func CacheExpires(r *http.Response) time.Time
- type APIClient
- type APIKey
- type APIResponse
- type AdditionLink
- type Artifact
- type ArtifactApiAddLabelOpts
- type ArtifactApiCopyArtifactOpts
- type ArtifactApiCreateTagOpts
- type ArtifactApiDeleteArtifactOpts
- type ArtifactApiDeleteTagOpts
- type ArtifactApiGetAdditionOpts
- type ArtifactApiGetArtifactOpts
- type ArtifactApiListArtifactsOpts
- type ArtifactApiListTagsOpts
- type ArtifactApiRemoveLabelOpts
- type ArtifactApiService
- func (a *ArtifactApiService) AddLabel(ctx context.Context, body Label, projectName string, repositoryName string, ...) (*http.Response, error)
- func (a *ArtifactApiService) CopyArtifact(ctx context.Context, projectName string, repositoryName string, from string, ...) (*http.Response, error)
- func (a *ArtifactApiService) CreateTag(ctx context.Context, body Tag, projectName string, repositoryName string, ...) (*http.Response, error)
- func (a *ArtifactApiService) DeleteArtifact(ctx context.Context, projectName string, repositoryName string, ...) (*http.Response, error)
- func (a *ArtifactApiService) DeleteTag(ctx context.Context, projectName string, repositoryName string, ...) (*http.Response, error)
- func (a *ArtifactApiService) GetAddition(ctx context.Context, projectName string, repositoryName string, ...) (string, *http.Response, error)
- func (a *ArtifactApiService) GetArtifact(ctx context.Context, projectName string, repositoryName string, ...) (Artifact, *http.Response, error)
- func (a *ArtifactApiService) ListArtifacts(ctx context.Context, projectName string, repositoryName string, ...) ([]Artifact, *http.Response, error)
- func (a *ArtifactApiService) ListTags(ctx context.Context, projectName string, repositoryName string, ...) ([]Tag, *http.Response, error)
- func (a *ArtifactApiService) RemoveLabel(ctx context.Context, projectName string, repositoryName string, ...) (*http.Response, error)
- type AuditLog
- type AuditlogApiListAuditLogsOpts
- type AuditlogApiService
- type BasicAuth
- type Configuration
- type Execution
- type GenericSwaggerError
- type Instance
- type InstanceCreatedResp
- type InstanceDeletedResp
- type InstanceUpdateResp
- type Label
- type Metadata
- type Metrics
- type ModelError
- type NativeReportSummary
- type Platform
- type PreheatApiCreateInstanceOpts
- type PreheatApiCreatePolicyOpts
- type PreheatApiDeleteInstanceOpts
- type PreheatApiDeletePolicyOpts
- type PreheatApiGetExecutionOpts
- type PreheatApiGetInstanceOpts
- type PreheatApiGetLogOpts
- type PreheatApiGetPolicyOpts
- type PreheatApiListExecutionsOpts
- type PreheatApiListInstancesOpts
- type PreheatApiListPoliciesOpts
- type PreheatApiListProvidersOpts
- type PreheatApiListProvidersUnderProjectOpts
- type PreheatApiListTasksOpts
- type PreheatApiManualPreheatOpts
- type PreheatApiPingInstancesOpts
- type PreheatApiService
- func (a *PreheatApiService) CreateInstance(ctx context.Context, body Instance, ...) (InstanceCreatedResp, *http.Response, error)
- func (a *PreheatApiService) CreatePolicy(ctx context.Context, body PreheatPolicy, projectName string, ...) (*http.Response, error)
- func (a *PreheatApiService) DeleteInstance(ctx context.Context, preheatInstanceName string, ...) (InstanceDeletedResp, *http.Response, error)
- func (a *PreheatApiService) DeletePolicy(ctx context.Context, projectName string, preheatPolicyName string, ...) (*http.Response, error)
- func (a *PreheatApiService) GetExecution(ctx context.Context, projectName string, preheatPolicyName string, ...) (Execution, *http.Response, error)
- func (a *PreheatApiService) GetInstance(ctx context.Context, preheatInstanceName string, ...) (Instance, *http.Response, error)
- func (a *PreheatApiService) GetLog(ctx context.Context, projectName string, preheatPolicyName string, ...) (string, *http.Response, error)
- func (a *PreheatApiService) GetPolicy(ctx context.Context, projectName string, preheatPolicyName string, ...) (PreheatPolicy, *http.Response, error)
- func (a *PreheatApiService) ListExecutions(ctx context.Context, projectName string, preheatPolicyName string, ...) ([]Execution, *http.Response, error)
- func (a *PreheatApiService) ListInstances(ctx context.Context, localVarOptionals *PreheatApiListInstancesOpts) ([]Instance, *http.Response, error)
- func (a *PreheatApiService) ListPolicies(ctx context.Context, projectName string, ...) ([]PreheatPolicy, *http.Response, error)
- func (a *PreheatApiService) ListProviders(ctx context.Context, localVarOptionals *PreheatApiListProvidersOpts) ([]Metadata, *http.Response, error)
- func (a *PreheatApiService) ListProvidersUnderProject(ctx context.Context, projectName string, ...) ([]ProviderUnderProject, *http.Response, error)
- func (a *PreheatApiService) ListTasks(ctx context.Context, projectName string, preheatPolicyName string, ...) ([]Task, *http.Response, error)
- func (a *PreheatApiService) ManualPreheat(ctx context.Context, body PreheatPolicy, projectName string, ...) (*http.Response, error)
- func (a *PreheatApiService) PingInstances(ctx context.Context, body Instance, ...) (*http.Response, error)
- func (a *PreheatApiService) StopExecution(ctx context.Context, body Execution, projectName string, ...) (*http.Response, error)
- func (a *PreheatApiService) UpdateInstance(ctx context.Context, body Instance, preheatInstanceName string, ...) (InstanceUpdateResp, *http.Response, error)
- func (a *PreheatApiService) UpdatePolicy(ctx context.Context, body PreheatPolicy, projectName string, ...) (*http.Response, error)
- type PreheatApiStopExecutionOpts
- type PreheatApiUpdateInstanceOpts
- type PreheatApiUpdatePolicyOpts
- type PreheatPolicy
- type ProjectApiGetLogsOpts
- type ProjectApiService
- type ProviderUnderProject
- type Reference
- type Repository
- type RepositoryApiDeleteRepositoryOpts
- type RepositoryApiGetRepositoryOpts
- type RepositoryApiListRepositoriesOpts
- type RepositoryApiService
- func (a *RepositoryApiService) DeleteRepository(ctx context.Context, projectName string, repositoryName string, ...) (*http.Response, error)
- func (a *RepositoryApiService) GetRepository(ctx context.Context, projectName string, repositoryName string, ...) (Repository, *http.Response, error)
- func (a *RepositoryApiService) ListRepositories(ctx context.Context, projectName string, ...) ([]Repository, *http.Response, error)
- func (a *RepositoryApiService) UpdateRepository(ctx context.Context, body Repository, projectName string, ...) (*http.Response, error)
- type RepositoryApiUpdateRepositoryOpts
- type ScanApiGetReportLogOpts
- type ScanApiScanArtifactOpts
- type ScanApiService
- type Tag
- type Task
- type VulnerabilitySummary
Constants ¶
This section is empty.
Variables ¶
var ( // ContextOAuth2 takes a oauth2.TokenSource as authentication for the request. ContextOAuth2 = contextKey("token") // ContextBasicAuth takes BasicAuth as authentication for the request. ContextBasicAuth = contextKey("basic") // ContextAccessToken takes a string oauth2 access token as authentication for the request. ContextAccessToken = contextKey("accesstoken") // ContextAPIKey takes an APIKey as authentication for the request ContextAPIKey = contextKey("apikey") )
Functions ¶
Types ¶
type APIClient ¶
type APIClient struct {
ArtifactApi *ArtifactApiService
AuditlogApi *AuditlogApiService
PreheatApi *PreheatApiService
ProjectApi *ProjectApiService
RepositoryApi *RepositoryApiService
ScanApi *ScanApiService
// contains filtered or unexported fields
}
APIClient manages communication with the Harbor API API v2.0 In most cases there should be only one, shared, APIClient.
func NewAPIClient ¶
func NewAPIClient(cfg *Configuration) *APIClient
NewAPIClient creates a new API client. Requires a userAgent string describing your application. optionally a custom http.Client to allow for advanced features such as caching.
func (*APIClient) ChangeBasePath ¶
Change base path to allow switching to mocks
type APIKey ¶
APIKey provides API key based authentication to a request passed via context using ContextAPIKey
type APIResponse ¶
type APIResponse struct {
*http.Response `json:"-"`
Message string `json:"message,omitempty"`
// Operation is the name of the swagger operation.
Operation string `json:"operation,omitempty"`
// RequestURL is the request URL. This value is always available, even if the
// embedded *http.Response is nil.
RequestURL string `json:"url,omitempty"`
// Method is the HTTP method used for the request. This value is always
// available, even if the embedded *http.Response is nil.
Method string `json:"method,omitempty"`
// Payload holds the contents of the response body (which may be nil or empty).
// This is provided here as the raw response.Body() reader will have already
// been drained.
Payload []byte `json:"-"`
}
func NewAPIResponse ¶
func NewAPIResponse(r *http.Response) *APIResponse
func NewAPIResponseWithError ¶
func NewAPIResponseWithError(errorMessage string) *APIResponse
type AdditionLink ¶
type Artifact ¶
type Artifact struct {
// The ID of the artifact
Id int64 `json:"id,omitempty"`
// The type of the artifact, e.g. image, chart, etc
Type_ string `json:"type,omitempty"`
// The media type of the artifact
MediaType string `json:"media_type,omitempty"`
// The manifest media type of the artifact
ManifestMediaType string `json:"manifest_media_type,omitempty"`
// The ID of the project that the artifact belongs to
ProjectId int64 `json:"project_id,omitempty"`
// The ID of the repository that the artifact belongs to
RepositoryId int64 `json:"repository_id,omitempty"`
// The digest of the artifact
Digest string `json:"digest,omitempty"`
// The size of the artifact
Size int64 `json:"size,omitempty"`
// The push time of the artifact
PushTime time.Time `json:"push_time,omitempty"`
// The latest pull time of the artifact
PullTime time.Time `json:"pull_time,omitempty"`
ExtraAttrs *ModelMap `json:"extra_attrs,omitempty"`
Annotations *ModelMap `json:"annotations,omitempty"`
References []Reference `json:"references,omitempty"`
Tags []Tag `json:"tags,omitempty"`
AdditionLinks *ModelMap `json:"addition_links,omitempty"`
Labels []Label `json:"labels,omitempty"`
ScanOverview *ModelMap `json:"scan_overview,omitempty"`
}
type ArtifactApiAddLabelOpts ¶
type ArtifactApiListTagsOpts ¶
type ArtifactApiService ¶
type ArtifactApiService service
func (*ArtifactApiService) CopyArtifact ¶
func (a *ArtifactApiService) CopyArtifact(ctx context.Context, projectName string, repositoryName string, from string, localVarOptionals *ArtifactApiCopyArtifactOpts) (*http.Response, error)
func (*ArtifactApiService) DeleteArtifact ¶
func (a *ArtifactApiService) DeleteArtifact(ctx context.Context, projectName string, repositoryName string, reference string, localVarOptionals *ArtifactApiDeleteArtifactOpts) (*http.Response, error)
func (*ArtifactApiService) GetAddition ¶
func (*ArtifactApiService) GetArtifact ¶
func (*ArtifactApiService) ListArtifacts ¶
func (a *ArtifactApiService) ListArtifacts(ctx context.Context, projectName string, repositoryName string, localVarOptionals *ArtifactApiListArtifactsOpts) ([]Artifact, *http.Response, error)
func (*ArtifactApiService) RemoveLabel ¶
type AuditLog ¶
type AuditLog struct {
// The ID of the audit log entry.
Id int32 `json:"id,omitempty"`
// Username of the user in this log entry.
Username string `json:"username,omitempty"`
// Name of the repository in this log entry.
Resource string `json:"resource,omitempty"`
// Tag of the repository in this log entry.
ResourceType string `json:"resource_type,omitempty"`
// The operation against the repository in this log entry.
Operation string `json:"operation,omitempty"`
// The time when this operation is triggered.
OpTime time.Time `json:"op_time,omitempty"`
}
type AuditlogApiService ¶
type AuditlogApiService service
func (*AuditlogApiService) ListAuditLogs ¶
func (a *AuditlogApiService) ListAuditLogs(ctx context.Context, localVarOptionals *AuditlogApiListAuditLogsOpts) ([]AuditLog, *http.Response, error)
type BasicAuth ¶
type BasicAuth struct {
UserName string `json:"userName,omitempty"`
Password string `json:"password,omitempty"`
}
BasicAuth provides basic http authentication to a request passed via context using ContextBasicAuth
type Configuration ¶
type Configuration struct {
BasePath string `json:"basePath,omitempty"`
Host string `json:"host,omitempty"`
Scheme string `json:"scheme,omitempty"`
DefaultHeader map[string]string `json:"defaultHeader,omitempty"`
UserAgent string `json:"userAgent,omitempty"`
HTTPClient *http.Client
}
func NewConfiguration ¶
func NewConfiguration() *Configuration
func (*Configuration) AddDefaultHeader ¶
func (c *Configuration) AddDefaultHeader(key string, value string)
type Execution ¶
type Execution struct {
// The ID of execution
Id int32 `json:"id,omitempty"`
// The vendor type of execution
VendorType string `json:"vendor_type,omitempty"`
// The vendor id of execution
VendorId int32 `json:"vendor_id,omitempty"`
// The status of execution
Status string `json:"status,omitempty"`
// The status message of execution
StatusMessage string `json:"status_message,omitempty"`
Metrics *Metrics `json:"metrics,omitempty"`
// The trigger of execution
Trigger string `json:"trigger,omitempty"`
ExtraAttrs *ModelMap `json:"extra_attrs,omitempty"`
// The start time of execution
StartTime string `json:"start_time,omitempty"`
// The end time of execution
EndTime string `json:"end_time,omitempty"`
}
type GenericSwaggerError ¶
type GenericSwaggerError struct {
// contains filtered or unexported fields
}
GenericSwaggerError Provides access to the body, error and model on returned errors.
func (GenericSwaggerError) Body ¶
func (e GenericSwaggerError) Body() []byte
Body returns the raw bytes of the response
func (GenericSwaggerError) Error ¶
func (e GenericSwaggerError) Error() string
Error returns non-empty string if there was an error.
func (GenericSwaggerError) Model ¶
func (e GenericSwaggerError) Model() interface{}
Model returns the unpacked model of the error
type Instance ¶
type Instance struct {
// Unique ID
Id int32 `json:"id,omitempty"`
// Instance name
Name string `json:"name,omitempty"`
// Description of instance
Description string `json:"description,omitempty"`
// Based on which driver, identified by ID
Vendor string `json:"vendor,omitempty"`
// The service endpoint of this instance
Endpoint string `json:"endpoint,omitempty"`
// The authentication way supported
AuthMode string `json:"auth_mode,omitempty"`
// The auth credential data if exists
AuthInfo map[string]string `json:"auth_info,omitempty"`
// The health status
Status string `json:"status,omitempty"`
// Whether the instance is activated or not
Enabled bool `json:"enabled,omitempty"`
// Whether the instance is default or not
Default_ bool `json:"default,omitempty"`
// Whether the instance endpoint is insecure or not
Insecure bool `json:"insecure,omitempty"`
// The timestamp of instance setting up
SetupTimestamp int64 `json:"setup_timestamp,omitempty"`
}
type InstanceCreatedResp ¶
type InstanceCreatedResp struct {
// ID of instance created
Id int32 `json:"id,omitempty"`
}
type InstanceDeletedResp ¶
type InstanceDeletedResp struct {
// ID of instance removed
Removed int32 `json:"removed,omitempty"`
}
type InstanceUpdateResp ¶
type InstanceUpdateResp struct {
// ID of instance updated
Updated int32 `json:"updated,omitempty"`
}
type Label ¶
type Label struct {
// The ID of the label
Id int64 `json:"id,omitempty"`
// The name the label
Name string `json:"name,omitempty"`
// The description the label
Description string `json:"description,omitempty"`
// The color the label
Color string `json:"color,omitempty"`
// The scope the label
Scope string `json:"scope,omitempty"`
// The ID of project that the label belongs to
ProjectId int64 `json:"project_id,omitempty"`
// The creation time the label
CreationTime time.Time `json:"creation_time,omitempty"`
// The update time of the label
UpdateTime time.Time `json:"update_time,omitempty"`
}
type Metadata ¶
type Metadata struct {
// id
Id string `json:"id,omitempty"`
// name
Name string `json:"name,omitempty"`
// icon
Icon string `json:"icon,omitempty"`
// maintainers
Maintainers []string `json:"maintainers,omitempty"`
// version
Version string `json:"version,omitempty"`
// source
Source string `json:"source,omitempty"`
}
type Metrics ¶
type Metrics struct {
// The count of task
TaskCount int32 `json:"task_count,omitempty"`
// The count of success task
SuccessTaskCount int32 `json:"success_task_count,omitempty"`
// The count of error task
ErrorTaskCount int32 `json:"error_task_count,omitempty"`
// The count of pending task
PendingTaskCount int32 `json:"pending_task_count,omitempty"`
// The count of running task
RunningTaskCount int32 `json:"running_task_count,omitempty"`
// The count of scheduled task
ScheduledTaskCount int32 `json:"scheduled_task_count,omitempty"`
// The count of stopped task
StoppedTaskCount int32 `json:"stopped_task_count,omitempty"`
}
type ModelError ¶
type ModelError struct {
// The error code
Code string `json:"code,omitempty"`
// The error message
Message string `json:"message,omitempty"`
}
a model for all the error response coming from harbor
type NativeReportSummary ¶
type NativeReportSummary struct {
// id of the native scan report
ReportId string `json:"report_id,omitempty"`
// The status of the report generating process
ScanStatus string `json:"scan_status,omitempty"`
// The overall severity
Severity string `json:"severity,omitempty"`
// The seconds spent for generating the report
Duration int64 `json:"duration,omitempty"`
Summary *VulnerabilitySummary `json:"summary,omitempty"`
// The start time of the scan process that generating report
StartTime time.Time `json:"start_time,omitempty"`
// The end time of the scan process that generating report
EndTime time.Time `json:"end_time,omitempty"`
// The complete percent of the scanning which value is between 0 and 100
CompletePercent int32 `json:"complete_percent,omitempty"`
}
The summary for the native report
type Platform ¶
type Platform struct {
// The architecture that the artifact applys to
Architecture string `json:"architecture,omitempty"`
// The OS that the artifact applys to
Os string `json:"os,omitempty"`
// The version of the OS that the artifact applys to
OsVersion string `json:"'os.version',omitempty"`
// The features of the OS that the artifact applys to
OsFeatures []string `json:"'os.features',omitempty"`
// The variant of the CPU
Variant string `json:"variant,omitempty"`
}
type PreheatApiGetLogOpts ¶
type PreheatApiGetPolicyOpts ¶
type PreheatApiListTasksOpts ¶
type PreheatApiService ¶
type PreheatApiService service
func (*PreheatApiService) CreateInstance ¶
func (a *PreheatApiService) CreateInstance(ctx context.Context, body Instance, localVarOptionals *PreheatApiCreateInstanceOpts) (InstanceCreatedResp, *http.Response, error)
func (*PreheatApiService) CreatePolicy ¶
func (a *PreheatApiService) CreatePolicy(ctx context.Context, body PreheatPolicy, projectName string, localVarOptionals *PreheatApiCreatePolicyOpts) (*http.Response, error)
func (*PreheatApiService) DeleteInstance ¶
func (a *PreheatApiService) DeleteInstance(ctx context.Context, preheatInstanceName string, localVarOptionals *PreheatApiDeleteInstanceOpts) (InstanceDeletedResp, *http.Response, error)
func (*PreheatApiService) DeletePolicy ¶
func (a *PreheatApiService) DeletePolicy(ctx context.Context, projectName string, preheatPolicyName string, localVarOptionals *PreheatApiDeletePolicyOpts) (*http.Response, error)
func (*PreheatApiService) GetExecution ¶
func (*PreheatApiService) GetInstance ¶
func (a *PreheatApiService) GetInstance(ctx context.Context, preheatInstanceName string, localVarOptionals *PreheatApiGetInstanceOpts) (Instance, *http.Response, error)
func (*PreheatApiService) GetPolicy ¶
func (a *PreheatApiService) GetPolicy(ctx context.Context, projectName string, preheatPolicyName string, localVarOptionals *PreheatApiGetPolicyOpts) (PreheatPolicy, *http.Response, error)
func (*PreheatApiService) ListExecutions ¶
func (a *PreheatApiService) ListExecutions(ctx context.Context, projectName string, preheatPolicyName string, localVarOptionals *PreheatApiListExecutionsOpts) ([]Execution, *http.Response, error)
func (*PreheatApiService) ListInstances ¶
func (a *PreheatApiService) ListInstances(ctx context.Context, localVarOptionals *PreheatApiListInstancesOpts) ([]Instance, *http.Response, error)
func (*PreheatApiService) ListPolicies ¶
func (a *PreheatApiService) ListPolicies(ctx context.Context, projectName string, localVarOptionals *PreheatApiListPoliciesOpts) ([]PreheatPolicy, *http.Response, error)
func (*PreheatApiService) ListProviders ¶
func (a *PreheatApiService) ListProviders(ctx context.Context, localVarOptionals *PreheatApiListProvidersOpts) ([]Metadata, *http.Response, error)
func (*PreheatApiService) ListProvidersUnderProject ¶
func (a *PreheatApiService) ListProvidersUnderProject(ctx context.Context, projectName string, localVarOptionals *PreheatApiListProvidersUnderProjectOpts) ([]ProviderUnderProject, *http.Response, error)
func (*PreheatApiService) ManualPreheat ¶
func (a *PreheatApiService) ManualPreheat(ctx context.Context, body PreheatPolicy, projectName string, preheatPolicyName string, localVarOptionals *PreheatApiManualPreheatOpts) (*http.Response, error)
func (*PreheatApiService) PingInstances ¶
func (a *PreheatApiService) PingInstances(ctx context.Context, body Instance, localVarOptionals *PreheatApiPingInstancesOpts) (*http.Response, error)
func (*PreheatApiService) StopExecution ¶
func (*PreheatApiService) UpdateInstance ¶
func (a *PreheatApiService) UpdateInstance(ctx context.Context, body Instance, preheatInstanceName string, localVarOptionals *PreheatApiUpdateInstanceOpts) (InstanceUpdateResp, *http.Response, error)
func (*PreheatApiService) UpdatePolicy ¶
func (a *PreheatApiService) UpdatePolicy(ctx context.Context, body PreheatPolicy, projectName string, preheatPolicyName string, localVarOptionals *PreheatApiUpdatePolicyOpts) (*http.Response, error)
type PreheatPolicy ¶
type PreheatPolicy struct {
// The ID of preheat policy
Id int32 `json:"id,omitempty"`
// The Name of preheat policy
Name string `json:"name,omitempty"`
// The Description of preheat policy
Description string `json:"description,omitempty"`
// The ID of preheat policy project
ProjectId int32 `json:"project_id,omitempty"`
// The ID of preheat policy provider
ProviderId int32 `json:"provider_id,omitempty"`
// The Name of preheat policy provider
ProviderName string `json:"provider_name,omitempty"`
// The Filters of preheat policy
Filters string `json:"filters,omitempty"`
// The Trigger of preheat policy
Trigger string `json:"trigger,omitempty"`
// Whether the preheat policy enabled
Enabled bool `json:"enabled,omitempty"`
// The Create Time of preheat policy
CreationTime time.Time `json:"creation_time,omitempty"`
// The Update Time of preheat policy
UpdateTime time.Time `json:"update_time,omitempty"`
}
type ProjectApiGetLogsOpts ¶
type ProjectApiService ¶
type ProjectApiService service
type ProviderUnderProject ¶
type Reference ¶
type Reference struct {
// The parent ID of the reference
ParentId int64 `json:"parent_id,omitempty"`
// The child ID of the reference
ChildId int64 `json:"child_id,omitempty"`
// The digest of the child artifact
ChildDigest string `json:"child_digest,omitempty"`
Platform *Platform `json:"platform,omitempty"`
Annotations *ModelMap `json:"annotations,omitempty"`
// The download URLs
Urls []string `json:"urls,omitempty"`
}
type Repository ¶
type Repository struct {
// The ID of the repository
Id int64 `json:"id,omitempty"`
// The ID of the project that the repository belongs to
ProjectId int64 `json:"project_id,omitempty"`
// The name of the repository
Name string `json:"name,omitempty"`
// The description of the repository
Description string `json:"description,omitempty"`
// The count of the artifacts inside the repository
ArtifactCount int64 `json:"artifact_count,omitempty"`
// The count that the artifact inside the repository pulled
PullCount int64 `json:"pull_count,omitempty"`
// The creation time of the repository
CreationTime time.Time `json:"creation_time,omitempty"`
// The update time of the repository
UpdateTime time.Time `json:"update_time,omitempty"`
}
type RepositoryApiService ¶
type RepositoryApiService service
func (*RepositoryApiService) DeleteRepository ¶
func (a *RepositoryApiService) DeleteRepository(ctx context.Context, projectName string, repositoryName string, localVarOptionals *RepositoryApiDeleteRepositoryOpts) (*http.Response, error)
func (*RepositoryApiService) GetRepository ¶
func (a *RepositoryApiService) GetRepository(ctx context.Context, projectName string, repositoryName string, localVarOptionals *RepositoryApiGetRepositoryOpts) (Repository, *http.Response, error)
func (*RepositoryApiService) ListRepositories ¶
func (a *RepositoryApiService) ListRepositories(ctx context.Context, projectName string, localVarOptionals *RepositoryApiListRepositoriesOpts) ([]Repository, *http.Response, error)
func (*RepositoryApiService) UpdateRepository ¶
func (a *RepositoryApiService) UpdateRepository(ctx context.Context, body Repository, projectName string, repositoryName string, localVarOptionals *RepositoryApiUpdateRepositoryOpts) (*http.Response, error)
type ScanApiGetReportLogOpts ¶
type ScanApiScanArtifactOpts ¶
type ScanApiService ¶
type ScanApiService service
func (*ScanApiService) GetReportLog ¶
func (*ScanApiService) ScanArtifact ¶
func (a *ScanApiService) ScanArtifact(ctx context.Context, projectName string, repositoryName string, reference string, localVarOptionals *ScanApiScanArtifactOpts) (*http.Response, error)
type Tag ¶
type Tag struct {
// The ID of the tag
Id int64 `json:"id,omitempty"`
// The ID of the repository that the tag belongs to
RepositoryId int64 `json:"repository_id,omitempty"`
// The ID of the artifact that the tag attached to
ArtifactId int64 `json:"artifact_id,omitempty"`
// The name of the tag
Name string `json:"name,omitempty"`
// The push time of the tag
PushTime time.Time `json:"push_time,omitempty"`
// The latest pull time of the tag
PullTime time.Time `json:"pull_time,omitempty"`
// The immutable status of the tag
Immutable bool `json:"immutable,omitempty"`
// The attribute indicates whether the tag is signed or not
Signed bool `json:"signed,omitempty"`
}
type Task ¶
type Task struct {
// The ID of task
Id int32 `json:"id,omitempty"`
// The ID of task execution
ExecutionId int32 `json:"execution_id,omitempty"`
// The status of task
Status string `json:"status,omitempty"`
// The status message of task
StatusMessage string `json:"status_message,omitempty"`
// The count of task run
RunCount int32 `json:"run_count,omitempty"`
ExtraAttrs *ModelMap `json:"extra_attrs,omitempty"`
// The creation time of task
CreationTime string `json:"creation_time,omitempty"`
// The update time of task
UpdateTime string `json:"update_time,omitempty"`
// The start time of task
StartTime string `json:"start_time,omitempty"`
// The end time of task
EndTime string `json:"end_time,omitempty"`
}
type VulnerabilitySummary ¶
type VulnerabilitySummary struct {
// The total number of the found vulnerabilities
Total int32 `json:"total,omitempty"`
// The number of the fixable vulnerabilities
Fixable int32 `json:"fixable,omitempty"`
// Numbers of the vulnerabilities with different severity
Summary map[string]int32 `json:"summary,omitempty"`
}
VulnerabilitySummary contains the total number of the foun d vulnerabilities number and numbers of each severity level.
Source Files
¶
- api_artifact.go
- api_auditlog.go
- api_preheat.go
- api_project.go
- api_repository.go
- api_scan.go
- client.go
- configuration.go
- model_addition_link.go
- model_artifact.go
- model_audit_log.go
- model_error.go
- model_execution.go
- model_instance.go
- model_instance_created_resp.go
- model_instance_deleted_resp.go
- model_instance_update_resp.go
- model_label.go
- model_metadata.go
- model_metrics.go
- model_native_report_summary.go
- model_platform.go
- model_preheat_policy.go
- model_provider_under_project.go
- model_reference.go
- model_repository.go
- model_tag.go
- model_task.go
- model_vulnerability_summary.go
- response.go