Documentation ¶
Overview ¶
Package clients provides primitives to interact with the openapi HTTP API.
Code generated by github.com/oapi-codegen/oapi-codegen/v2 version v2.3.0 DO NOT EDIT.
Index ¶
- type ActualVersion
- type AnalyticsAttributes
- type AnalyticsData
- type AnalyticsRequestBody
- type Application
- type CreateAnalyticsJSONRequestBody
- type CreateAnalyticsParams
- type Environment
- type Error
- type ErrorDocument
- type ErrorLink
- type Integration
- type Interaction
- type InteractionError
- type InteractionStage
- type JsonApi
- type LinkProperty
- func (t LinkProperty) AsLinkProperty0() (LinkProperty0, error)
- func (t LinkProperty) AsLinkProperty1() (LinkProperty1, error)
- func (t *LinkProperty) FromLinkProperty0(v LinkProperty0) error
- func (t *LinkProperty) FromLinkProperty1(v LinkProperty1) error
- func (t LinkProperty) MarshalJSON() ([]byte, error)
- func (t *LinkProperty) MergeLinkProperty0(v LinkProperty0) error
- func (t *LinkProperty) MergeLinkProperty1(v LinkProperty1) error
- func (t *LinkProperty) UnmarshalJSON(b []byte) error
- type LinkProperty0
- type LinkProperty1
- type Meta
- type N400
- type N404
- type N500
- type OrgId
- type Performance
- type Platform
- type QueryVersion
- type Runtime
- type Target
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AnalyticsAttributes ¶
type AnalyticsAttributes struct { Interaction Interaction `json:"interaction"` Runtime *Runtime `json:"runtime,omitempty"` }
AnalyticsAttributes defines model for AnalyticsAttributes.
type AnalyticsData ¶
type AnalyticsData struct { Attributes AnalyticsAttributes `json:"attributes"` // Type The type of data ("analytics"). Type string `json:"type"` }
AnalyticsData defines model for AnalyticsData.
type AnalyticsRequestBody ¶
type AnalyticsRequestBody struct {
Data AnalyticsData `json:"data"`
}
AnalyticsRequestBody defines model for AnalyticsRequestBody.
type Application ¶
Application The application name, e.g. snyk-ls. The version of the integration.
type CreateAnalyticsJSONRequestBody ¶
type CreateAnalyticsJSONRequestBody = AnalyticsRequestBody
CreateAnalyticsJSONRequestBody defines body for CreateAnalytics for application/json ContentType.
type CreateAnalyticsParams ¶
type CreateAnalyticsParams struct { // Version The requested version of the endpoint to process the request Version QueryVersion `form:"version" json:"version"` }
CreateAnalyticsParams defines parameters for CreateAnalytics.
type Environment ¶
Environment The environment for the integration (e.g., IntelliJ Ultimate, Pycharm). The version of the integration environment (e.g. 2023.3)
type Error ¶
type Error struct { // Code An application-specific error code, expressed as a string value. Code *string `json:"code,omitempty"` // Detail A human-readable explanation specific to this occurrence of the problem. Detail string `json:"detail"` // Id A unique identifier for this particular occurrence of the problem. Id *openapi_types.UUID `json:"id,omitempty"` // Links A link that leads to further details about this particular occurrance of the problem. Links *ErrorLink `json:"links,omitempty"` Meta *map[string]interface{} `json:"meta,omitempty"` Source *struct { // Parameter A string indicating which URI query parameter caused the error. Parameter *string `json:"parameter,omitempty"` // Pointer A JSON Pointer [RFC6901] to the associated entity in the request document. Pointer *string `json:"pointer,omitempty"` } `json:"source,omitempty"` // Status The HTTP status code applicable to this problem, expressed as a string value. Status string `json:"status"` // Title A short, human-readable summary of the problem that SHOULD NOT change from occurrence to occurrence of the problem, except for purposes of localization. Title *string `json:"title,omitempty"` }
Error defines model for Error.
type ErrorDocument ¶
ErrorDocument defines model for ErrorDocument.
type ErrorLink ¶
type ErrorLink struct {
About *LinkProperty `json:"about,omitempty"`
}
ErrorLink A link that leads to further details about this particular occurrance of the problem.
type Integration ¶
Integration TODO UPDATE with correct samples of integration name. The name of the integration, could be a plugin or extension (e.g. Snyk Security plugin for intelliJ). The version of the integration (2.3.4).
type Interaction ¶
type Interaction struct { // Categories The category vector used to describe the interaction in detail, "oss","test". Categories *[]string `json:"categories,omitempty"` Errors *[]InteractionError `json:"errors,omitempty"` // Extension Optional additional extension. // // Only strings, integers, and boolean values are allowed. Extension *map[string]interface{} `json:"extension,omitempty"` // Id The client-generated ID of the interaction event in the form of `urn:snyk:interaction:00000000-0000-0000-0000-000000000000` Id string `json:"id"` // Results The result of the interaction. Could be a something like this [{"name": "critical", "count": 0}]. // Only strings, integers, and boolean values are allowed. Results *[]map[string]interface{} `json:"results,omitempty"` // Stage The stage of the SDLC where the Interaction occurred, such as"dev"|"cicd"|"prchecks"|"unknown". Stage *InteractionStage `json:"stage,omitempty"` // Status Status would be "success" or "failure", where success means the action was executed, while failure means it didn't run. Status string `json:"status"` Target Target `json:"target"` // TimestampMs The timestamp in epoch milliseconds when the interaction was started in UTC (Zulu time). TimestampMs int64 `json:"timestamp_ms"` // Type The type of interaction, could be "Scan done". Scan Done indicates that a test was run no matter if the CLI or IDE ran it, other types can be freely chosen types. Type string `json:"type"` }
Interaction defines model for Interaction.
type InteractionError ¶
type InteractionError struct { // Code The HTTP specific error code. Code *string `json:"code,omitempty"` // Id Error identifier corresponding to the errors defined in the error catalog. // // `https://docs.snyk.io/scan-with-snyk/error-catalog` Id string `json:"id"` }
InteractionError defines model for InteractionError.
type InteractionStage ¶
type InteractionStage string
InteractionStage The stage of the SDLC where the Interaction occurred, such as"dev"|"cicd"|"prchecks"|"unknown".
const ( Cicd InteractionStage = "cicd" Dev InteractionStage = "dev" Prchecks InteractionStage = "prchecks" Unknown InteractionStage = "unknown" )
Defines values for InteractionStage.
type JsonApi ¶
type JsonApi struct { // Version Version of the JSON API specification this server supports. Version string `json:"version"` }
JsonApi defines model for JsonApi.
type LinkProperty ¶
type LinkProperty struct {
// contains filtered or unexported fields
}
LinkProperty defines model for LinkProperty.
func (LinkProperty) AsLinkProperty0 ¶
func (t LinkProperty) AsLinkProperty0() (LinkProperty0, error)
AsLinkProperty0 returns the union data inside the LinkProperty as a LinkProperty0
func (LinkProperty) AsLinkProperty1 ¶
func (t LinkProperty) AsLinkProperty1() (LinkProperty1, error)
AsLinkProperty1 returns the union data inside the LinkProperty as a LinkProperty1
func (*LinkProperty) FromLinkProperty0 ¶
func (t *LinkProperty) FromLinkProperty0(v LinkProperty0) error
FromLinkProperty0 overwrites any union data inside the LinkProperty as the provided LinkProperty0
func (*LinkProperty) FromLinkProperty1 ¶
func (t *LinkProperty) FromLinkProperty1(v LinkProperty1) error
FromLinkProperty1 overwrites any union data inside the LinkProperty as the provided LinkProperty1
func (LinkProperty) MarshalJSON ¶
func (t LinkProperty) MarshalJSON() ([]byte, error)
func (*LinkProperty) MergeLinkProperty0 ¶
func (t *LinkProperty) MergeLinkProperty0(v LinkProperty0) error
MergeLinkProperty0 performs a merge with any union data inside the LinkProperty, using the provided LinkProperty0
func (*LinkProperty) MergeLinkProperty1 ¶
func (t *LinkProperty) MergeLinkProperty1(v LinkProperty1) error
MergeLinkProperty1 performs a merge with any union data inside the LinkProperty, using the provided LinkProperty1
func (*LinkProperty) UnmarshalJSON ¶
func (t *LinkProperty) UnmarshalJSON(b []byte) error
type LinkProperty1 ¶
type LinkProperty1 struct { // Href A string containing the link’s URL. Href string `json:"href"` // Meta Free-form object that may contain non-standard information. Meta *Meta `json:"meta,omitempty"` }
LinkProperty1 defines model for .
type Meta ¶
type Meta map[string]interface{}
Meta Free-form object that may contain non-standard information.
type Performance ¶
type Performance struct {
DurationMs int64 `json:"duration_ms"`
}
Performance The scan duration in milliseconds
type Runtime ¶
type Runtime struct { // Application The application name, e.g. snyk-ls. The version of the integration. Application *Application `json:"application,omitempty"` // Environment The environment for the integration (e.g., IntelliJ Ultimate, Pycharm). The version of the integration environment (e.g. 2023.3) Environment *Environment `json:"environment,omitempty"` // Integration TODO UPDATE with correct samples of integration name. The name of the integration, could be a plugin or extension (e.g. Snyk Security plugin for intelliJ). The version of the integration (2.3.4). Integration *Integration `json:"integration,omitempty"` // Performance The scan duration in milliseconds Performance *Performance `json:"performance,omitempty"` // Platform The operating system and the architecture (AMD64, ARM64, 386, ALPINE). Platform *Platform `json:"platform,omitempty"` }
Runtime defines model for Runtime.
type Target ¶
type Target struct { // Id A purl is a URL composed of seven components. // scheme:type/namespace/name@version?qualifiers#subpath // // The purl specification is available here: // // `https://github.com/package-url/purl-spec` // // Some purl examples // // `pkg:github/package-url/purl-spec@244fd47e07d1004f0aed9c` // // `pkg:npm/%40angular/animation@12.3.1` // // `pkg:pypi/django@1.11.1` Id string `json:"id"` }
Target defines model for Target.