client

package
v1.0.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 14, 2023 License: MIT Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AbortChecksPath

func AbortChecksPath(id uuid.UUID) string

AbortChecksPath computes a request path to the abort action of Checks.

func AbortScansPath

func AbortScansPath(id uuid.UUID) string

AbortScansPath computes a request path to the abort action of Scans.

func ChecksScansPath

func ChecksScansPath(id uuid.UUID) string

ChecksScansPath computes a request path to the checks action of Scans.

func CreateChecksPath

func CreateChecksPath() string

CreateChecksPath computes a request path to the create action of Checks.

func CreateScansPath

func CreateScansPath() string

CreateScansPath computes a request path to the create action of Scans.

func IndexAgentsPath

func IndexAgentsPath() string

IndexAgentsPath computes a request path to the index action of Agents.

func IndexAssettypesPath

func IndexAssettypesPath() string

IndexAssettypesPath computes a request path to the index action of Assettypes.

func IndexChecktypesPath

func IndexChecktypesPath() string

IndexChecktypesPath computes a request path to the index action of Checktypes.

func IndexScansPath

func IndexScansPath() string

IndexScansPath computes a request path to the index action of Scans.

func KillChecksPath

func KillChecksPath(id uuid.UUID) string

KillChecksPath computes a request path to the kill action of Checks.

func PauseAgentsPath

func PauseAgentsPath(id uuid.UUID) string

PauseAgentsPath computes a request path to the pause action of Agents.

func ShowAgentsPath

func ShowAgentsPath(id uuid.UUID) string

ShowAgentsPath computes a request path to the show action of Agents.

func ShowChecksPath

func ShowChecksPath(id uuid.UUID) string

ShowChecksPath computes a request path to the show action of Checks.

func ShowChecktypesPath

func ShowChecktypesPath(id uuid.UUID) string

ShowChecktypesPath computes a request path to the show action of Checktypes.

func ShowHealthcheckPath

func ShowHealthcheckPath() string

ShowHealthcheckPath computes a request path to the show action of healthcheck.

func ShowScansPath

func ShowScansPath(id uuid.UUID) string

ShowScansPath computes a request path to the show action of Scans.

func StatsScansPath

func StatsScansPath(id uuid.UUID) string

StatsScansPath computes a request path to the stats action of Scans.

func UploadFileScansPath

func UploadFileScansPath() string

UploadFileScansPath computes a request path to the upload action of FileScans.

Types

type Agent

type Agent struct {
	Agent *Agentdata `form:"agent" json:"agent" yaml:"agent" xml:"agent"`
}

Agent media type (default view)

Identifier: application/vnd.agent+json; view=default

func (*Agent) Validate

func (mt *Agent) Validate() (err error)

Validate validates the Agent media type instance.

type AgentData

type AgentData struct {
	ID     uuid.UUID `form:"id" json:"id" yaml:"id" xml:"id"`
	Status string    `form:"status" json:"status" yaml:"status" xml:"status"`
}

AgentData user type.

func (*AgentData) Validate

func (ut *AgentData) Validate() (err error)

Validate validates the AgentData type instance.

type Agentdata

type Agentdata struct {
	Enabled    bool      `form:"enabled" json:"enabled" yaml:"enabled" xml:"enabled"`
	HeartbetAt time.Time `form:"heartbet_at" json:"heartbet_at" yaml:"heartbet_at" xml:"heartbet_at"`
	ID         uuid.UUID `form:"id" json:"id" yaml:"id" xml:"id"`
	Jobqueue   *Jobqueue `form:"jobqueue" json:"jobqueue" yaml:"jobqueue" xml:"jobqueue"`
	Status     string    `form:"status" json:"status" yaml:"status" xml:"status"`
	Version    string    `form:"version" json:"version" yaml:"version" xml:"version"`
}

Agentdata media type (default view)

Identifier: application/vnd.agentdata+json; view=default

func (*Agentdata) Validate

func (mt *Agentdata) Validate() (err error)

Validate validates the Agentdata media type instance.

type Agentjobqueuedata

type Agentjobqueuedata struct {
	Arn         string    `form:"arn" json:"arn" yaml:"arn" xml:"arn"`
	Description string    `form:"description" json:"description" yaml:"description" xml:"description"`
	Enabled     bool      `form:"enabled" json:"enabled" yaml:"enabled" xml:"enabled"`
	ID          uuid.UUID `form:"id" json:"id" yaml:"id" xml:"id"`
}

Agentjobqueuedata media type (default view)

Identifier: application/vnd.agentjobqueuedata+json; view=default

func (*Agentjobqueuedata) Validate

func (mt *Agentjobqueuedata) Validate() (err error)

Validate validates the Agentjobqueuedata media type instance.

type Agents

type Agents struct {
	Agents []*AgentData `form:"agents" json:"agents" yaml:"agents" xml:"agents"`
}

Agents media type (default view)

Identifier: application/vnd.agents+json; view=default

func (*Agents) Validate

func (mt *Agents) Validate() (err error)

Validate validates the Agents media type instance.

type Assettype

type Assettype struct {
	Assettype *string  `form:"assettype,omitempty" json:"assettype,omitempty" yaml:"assettype,omitempty" xml:"assettype,omitempty"`
	Name      []string `form:"name,omitempty" json:"name,omitempty" yaml:"name,omitempty" xml:"name,omitempty"`
}

Assettype media type (default view)

Identifier: application/vnd.assettype+json; view=default

type AssettypeCollection

type AssettypeCollection []*Assettype

AssettypeCollection is the media type for an array of Assettype (default view)

Identifier: application/vnd.assettype+json; type=collection; view=default

type AssettypeType

type AssettypeType struct {
	Assettype *string  `form:"assettype,omitempty" json:"assettype,omitempty" yaml:"assettype,omitempty" xml:"assettype,omitempty"`
	Name      []string `form:"name,omitempty" json:"name,omitempty" yaml:"name,omitempty" xml:"name,omitempty"`
}

AssettypeType user type.

type Check

type Check struct {
	Check *Checkdata `form:"check" json:"check" yaml:"check" xml:"check"`
}

Check media type (default view)

Identifier: application/vnd.check+json; view=default

func (*Check) Validate

func (mt *Check) Validate() (err error)

Validate validates the Check media type instance.

type CheckData

type CheckData struct {
	// Name of the checktype this check is
	ChecktypeName *string `` /* 126-byte string literal not displayed */
	// ID of the specific queue this check must we enqueued.
	// 		The queue must already be created in vulcan core.
	JobqueueID *uuid.UUID `form:"jobqueue_id,omitempty" json:"jobqueue_id,omitempty" yaml:"jobqueue_id,omitempty" xml:"jobqueue_id,omitempty"`
	// Configuration options for the Check. It should be in JSON format
	Options *string `form:"options,omitempty" json:"options,omitempty" yaml:"options,omitempty" xml:"options,omitempty"`
	// a tag
	Tag *string `form:"tag,omitempty" json:"tag,omitempty" yaml:"tag,omitempty" xml:"tag,omitempty"`
	// Target to be scanned. Can be a domain, hostname, IP or URL
	Target string `form:"target" json:"target" yaml:"target" xml:"target"`
	// Webhook to callback after the Check has finished
	Webhook *string `form:"webhook,omitempty" json:"webhook,omitempty" yaml:"webhook,omitempty" xml:"webhook,omitempty"`
}

CheckData user type.

func (*CheckData) Validate

func (ut *CheckData) Validate() (err error)

Validate validates the CheckData type instance.

type CheckPayload

type CheckPayload struct {
	Check *CheckData `form:"check" json:"check" yaml:"check" xml:"check"`
}

CheckPayload user type.

func (*CheckPayload) Validate

func (ut *CheckPayload) Validate() (err error)

Validate validates the CheckPayload type instance.

type Checkdata

type Checkdata struct {
	Checktype *ChecktypeType `form:"checktype" json:"checktype" yaml:"checktype" xml:"checktype"`
	ID        uuid.UUID      `form:"id" json:"id" yaml:"id" xml:"id"`
	// Configuration options for the Check. It should be in JSON format
	Options  *string   `form:"options,omitempty" json:"options,omitempty" yaml:"options,omitempty" xml:"options,omitempty"`
	Progress *float64  `form:"progress,omitempty" json:"progress,omitempty" yaml:"progress,omitempty" xml:"progress,omitempty"`
	Raw      *string   `form:"raw,omitempty" json:"raw,omitempty" yaml:"raw,omitempty" xml:"raw,omitempty"`
	Report   *string   `form:"report,omitempty" json:"report,omitempty" yaml:"report,omitempty" xml:"report,omitempty"`
	Scan     *Scandata `form:"scan,omitempty" json:"scan,omitempty" yaml:"scan,omitempty" xml:"scan,omitempty"`
	Status   string    `form:"status" json:"status" yaml:"status" xml:"status"`
	// Target to be scanned. Can be a domain, hostname, IP or URL
	Target string `form:"target" json:"target" yaml:"target" xml:"target"`
	// Webhook to callback after the Check has finished
	Webhook *string `form:"webhook,omitempty" json:"webhook,omitempty" yaml:"webhook,omitempty" xml:"webhook,omitempty"`
}

Checkdata media type (default view)

Identifier: application/vnd.checkdata+json; view=default

func (*Checkdata) Validate

func (mt *Checkdata) Validate() (err error)

Validate validates the Checkdata media type instance.

type Checks

type Checks struct {
	Checks []*Scancheckdata `form:"checks" json:"checks" yaml:"checks" xml:"checks"`
}

Checks media type (default view)

Identifier: application/vnd.checks+json; view=default

func (*Checks) Validate

func (mt *Checks) Validate() (err error)

Validate validates the Checks media type instance.

type Checktype

type Checktype struct {
	Checktype *ChecktypeType `form:"checktype" json:"checktype" yaml:"checktype" xml:"checktype"`
}

Checktype media type (default view)

Identifier: application/vnd.checktype+json; view=default

func (*Checktype) Validate

func (mt *Checktype) Validate() (err error)

Validate validates the Checktype media type instance.

type ChecktypeType

type ChecktypeType struct {
	Description *string   `form:"description,omitempty" json:"description,omitempty" yaml:"description,omitempty" xml:"description,omitempty"`
	Enabled     *bool     `form:"enabled,omitempty" json:"enabled,omitempty" yaml:"enabled,omitempty" xml:"enabled,omitempty"`
	ID          uuid.UUID `form:"id" json:"id" yaml:"id" xml:"id"`
	// Image that needs to be pulled to run the Check of this type
	Image string `form:"image" json:"image" yaml:"image" xml:"image"`
	Name  string `form:"name" json:"name" yaml:"name" xml:"name"`
	// Default configuration options for the Checktype. It should be in JSON format
	Options *string `form:"options,omitempty" json:"options,omitempty" yaml:"options,omitempty" xml:"options,omitempty"`
	// Specifies the maximum amount of time that the check should be running before it's killed
	Timeout *int `form:"timeout,omitempty" json:"timeout,omitempty" yaml:"timeout,omitempty" xml:"timeout,omitempty"`
}

ChecktypeType user type.

func (*ChecktypeType) Validate

func (ut *ChecktypeType) Validate() (err error)

Validate validates the ChecktypeType type instance.

type Checktypes

type Checktypes struct {
	Checktypes []*ChecktypeType `form:"checktypes" json:"checktypes" yaml:"checktypes" xml:"checktypes"`
}

Checktypes media type (default view)

Identifier: application/vnd.checktypes+json; view=default

func (*Checktypes) Validate

func (mt *Checktypes) Validate() (err error)

Validate validates the Checktypes media type instance.

type Client

type Client struct {
	*goaclient.Client
	Encoder *goa.HTTPEncoder
	Decoder *goa.HTTPDecoder
}

Client is the vulcan-persistence service client.

func New

func New(c goaclient.Doer) *Client

New instantiates the client.

func (*Client) AbortChecks

func (c *Client) AbortChecks(ctx context.Context, path string) (*http.Response, error)

Abort a Check gracefully

func (*Client) AbortScans

func (c *Client) AbortScans(ctx context.Context, path string) (*http.Response, error)

Abort a scan

func (*Client) ChecksScans

func (c *Client) ChecksScans(ctx context.Context, path string) (*http.Response, error)

Get checks of the Scan

func (*Client) CreateChecks

func (c *Client) CreateChecks(ctx context.Context, path string, payload *CheckPayload) (*http.Response, error)

Create a new Check

func (*Client) CreateScans

func (c *Client) CreateScans(ctx context.Context, path string, payload *ScanPayload) (*http.Response, error)

Create a new Scan

func (*Client) DecodeAgent

func (c *Client) DecodeAgent(resp *http.Response) (*Agent, error)

DecodeAgent decodes the Agent instance encoded in resp body.

func (*Client) DecodeAgentdata

func (c *Client) DecodeAgentdata(resp *http.Response) (*Agentdata, error)

DecodeAgentdata decodes the Agentdata instance encoded in resp body.

func (*Client) DecodeAgentjobqueuedata

func (c *Client) DecodeAgentjobqueuedata(resp *http.Response) (*Agentjobqueuedata, error)

DecodeAgentjobqueuedata decodes the Agentjobqueuedata instance encoded in resp body.

func (*Client) DecodeAgents

func (c *Client) DecodeAgents(resp *http.Response) (*Agents, error)

DecodeAgents decodes the Agents instance encoded in resp body.

func (*Client) DecodeAssettype

func (c *Client) DecodeAssettype(resp *http.Response) (*Assettype, error)

DecodeAssettype decodes the Assettype instance encoded in resp body.

func (*Client) DecodeAssettypeCollection

func (c *Client) DecodeAssettypeCollection(resp *http.Response) (AssettypeCollection, error)

DecodeAssettypeCollection decodes the AssettypeCollection instance encoded in resp body.

func (*Client) DecodeCheck

func (c *Client) DecodeCheck(resp *http.Response) (*Check, error)

DecodeCheck decodes the Check instance encoded in resp body.

func (*Client) DecodeCheckdata

func (c *Client) DecodeCheckdata(resp *http.Response) (*Checkdata, error)

DecodeCheckdata decodes the Checkdata instance encoded in resp body.

func (*Client) DecodeChecks

func (c *Client) DecodeChecks(resp *http.Response) (*Checks, error)

DecodeChecks decodes the Checks instance encoded in resp body.

func (*Client) DecodeChecktype

func (c *Client) DecodeChecktype(resp *http.Response) (*Checktype, error)

DecodeChecktype decodes the Checktype instance encoded in resp body.

func (*Client) DecodeChecktypes

func (c *Client) DecodeChecktypes(resp *http.Response) (*Checktypes, error)

DecodeChecktypes decodes the Checktypes instance encoded in resp body.

func (*Client) DecodeErrorResponse

func (c *Client) DecodeErrorResponse(resp *http.Response) (*goa.ErrorResponse, error)

DecodeErrorResponse decodes the ErrorResponse instance encoded in resp body.

func (*Client) DecodeJobqueue

func (c *Client) DecodeJobqueue(resp *http.Response) (*Jobqueue, error)

DecodeJobqueue decodes the Jobqueue instance encoded in resp body.

func (*Client) DecodeScan

func (c *Client) DecodeScan(resp *http.Response) (*Scan, error)

DecodeScan decodes the Scan instance encoded in resp body.

func (*Client) DecodeScancheckdata

func (c *Client) DecodeScancheckdata(resp *http.Response) (*Scancheckdata, error)

DecodeScancheckdata decodes the Scancheckdata instance encoded in resp body.

func (*Client) DecodeScandata

func (c *Client) DecodeScandata(resp *http.Response) (*Scandata, error)

DecodeScandata decodes the Scandata instance encoded in resp body.

func (*Client) DecodeScans

func (c *Client) DecodeScans(resp *http.Response) (*Scans, error)

DecodeScans decodes the Scans instance encoded in resp body.

func (*Client) DecodeStat

func (c *Client) DecodeStat(resp *http.Response) (*Stat, error)

DecodeStat decodes the Stat instance encoded in resp body.

func (*Client) DecodeStats

func (c *Client) DecodeStats(resp *http.Response) (*Stats, error)

DecodeStats decodes the Stats instance encoded in resp body.

func (*Client) DownloadSwaggerJSON

func (c *Client) DownloadSwaggerJSON(ctx context.Context, dest string) (int64, error)

DownloadSwaggerJSON downloads swagger.json and writes it to the file dest. It returns the number of bytes downloaded in case of success.

func (*Client) IndexAgents

func (c *Client) IndexAgents(ctx context.Context, path string, status *string) (*http.Response, error)

Get all agents

func (*Client) IndexAssettypes

func (c *Client) IndexAssettypes(ctx context.Context, path string) (*http.Response, error)

Get all assettypes and per each one the checktypes that are accepting that concrete assettype

func (*Client) IndexChecktypes

func (c *Client) IndexChecktypes(ctx context.Context, path string, enabled *string) (*http.Response, error)

Get all checktypes

func (*Client) IndexScans

func (c *Client) IndexScans(ctx context.Context, path string) (*http.Response, error)

Get all scans

func (*Client) KillChecks

func (c *Client) KillChecks(ctx context.Context, path string) (*http.Response, error)

Kill a Check immediately

func (*Client) NewAbortChecksRequest

func (c *Client) NewAbortChecksRequest(ctx context.Context, path string) (*http.Request, error)

NewAbortChecksRequest create the request corresponding to the abort action endpoint of the Checks resource.

func (*Client) NewAbortScansRequest

func (c *Client) NewAbortScansRequest(ctx context.Context, path string) (*http.Request, error)

NewAbortScansRequest create the request corresponding to the abort action endpoint of the Scans resource.

func (*Client) NewChecksScansRequest

func (c *Client) NewChecksScansRequest(ctx context.Context, path string) (*http.Request, error)

NewChecksScansRequest create the request corresponding to the checks action endpoint of the Scans resource.

func (*Client) NewCreateChecksRequest

func (c *Client) NewCreateChecksRequest(ctx context.Context, path string, payload *CheckPayload) (*http.Request, error)

NewCreateChecksRequest create the request corresponding to the create action endpoint of the Checks resource.

func (*Client) NewCreateScansRequest

func (c *Client) NewCreateScansRequest(ctx context.Context, path string, payload *ScanPayload) (*http.Request, error)

NewCreateScansRequest create the request corresponding to the create action endpoint of the Scans resource.

func (*Client) NewIndexAgentsRequest

func (c *Client) NewIndexAgentsRequest(ctx context.Context, path string, status *string) (*http.Request, error)

NewIndexAgentsRequest create the request corresponding to the index action endpoint of the Agents resource.

func (*Client) NewIndexAssettypesRequest

func (c *Client) NewIndexAssettypesRequest(ctx context.Context, path string) (*http.Request, error)

NewIndexAssettypesRequest create the request corresponding to the index action endpoint of the Assettypes resource.

func (*Client) NewIndexChecktypesRequest

func (c *Client) NewIndexChecktypesRequest(ctx context.Context, path string, enabled *string) (*http.Request, error)

NewIndexChecktypesRequest create the request corresponding to the index action endpoint of the Checktypes resource.

func (*Client) NewIndexScansRequest

func (c *Client) NewIndexScansRequest(ctx context.Context, path string) (*http.Request, error)

NewIndexScansRequest create the request corresponding to the index action endpoint of the Scans resource.

func (*Client) NewKillChecksRequest

func (c *Client) NewKillChecksRequest(ctx context.Context, path string) (*http.Request, error)

NewKillChecksRequest create the request corresponding to the kill action endpoint of the Checks resource.

func (*Client) NewPauseAgentsRequest

func (c *Client) NewPauseAgentsRequest(ctx context.Context, path string) (*http.Request, error)

NewPauseAgentsRequest create the request corresponding to the pause action endpoint of the Agents resource.

func (*Client) NewShowAgentsRequest

func (c *Client) NewShowAgentsRequest(ctx context.Context, path string) (*http.Request, error)

NewShowAgentsRequest create the request corresponding to the show action endpoint of the Agents resource.

func (*Client) NewShowChecksRequest

func (c *Client) NewShowChecksRequest(ctx context.Context, path string) (*http.Request, error)

NewShowChecksRequest create the request corresponding to the show action endpoint of the Checks resource.

func (*Client) NewShowChecktypesRequest

func (c *Client) NewShowChecktypesRequest(ctx context.Context, path string) (*http.Request, error)

NewShowChecktypesRequest create the request corresponding to the show action endpoint of the Checktypes resource.

func (*Client) NewShowHealthcheckRequest

func (c *Client) NewShowHealthcheckRequest(ctx context.Context, path string) (*http.Request, error)

NewShowHealthcheckRequest create the request corresponding to the show action endpoint of the healthcheck resource.

func (*Client) NewShowScansRequest

func (c *Client) NewShowScansRequest(ctx context.Context, path string) (*http.Request, error)

NewShowScansRequest create the request corresponding to the show action endpoint of the Scans resource.

func (*Client) NewStatsScansRequest

func (c *Client) NewStatsScansRequest(ctx context.Context, path string) (*http.Request, error)

NewStatsScansRequest create the request corresponding to the stats action endpoint of the Scans resource.

func (*Client) NewUploadFileScansRequest

func (c *Client) NewUploadFileScansRequest(ctx context.Context, path string, payload *FileScanPayload) (*http.Request, error)

NewUploadFileScansRequest create the request corresponding to the upload action endpoint of the FileScans resource.

func (*Client) PauseAgents

func (c *Client) PauseAgents(ctx context.Context, path string) (*http.Response, error)

Pause an agent

func (*Client) ShowAgents

func (c *Client) ShowAgents(ctx context.Context, path string) (*http.Response, error)

Get an Agent by its ID

func (*Client) ShowChecks

func (c *Client) ShowChecks(ctx context.Context, path string) (*http.Response, error)

Get a Check by its ID

func (*Client) ShowChecktypes

func (c *Client) ShowChecktypes(ctx context.Context, path string) (*http.Response, error)

Get a Checktype by its ID

func (*Client) ShowHealthcheck

func (c *Client) ShowHealthcheck(ctx context.Context, path string) (*http.Response, error)

Get the health status for the application

func (*Client) ShowScans

func (c *Client) ShowScans(ctx context.Context, path string) (*http.Response, error)

Get a Scan by its ID

func (*Client) StatsScans

func (c *Client) StatsScans(ctx context.Context, path string) (*http.Response, error)

Get stats of the Scan

func (*Client) UploadFileScans

func (c *Client) UploadFileScans(ctx context.Context, path string, payload *FileScanPayload) (*http.Response, error)

Create a scan by uploading a file using a multipart form with the scan definition

type FileScanPayload

type FileScanPayload struct {
	// Upload
	Upload string `form:"upload" json:"upload" yaml:"upload" xml:"upload"`
}

FileScanPayload user type.

func (*FileScanPayload) Validate

func (ut *FileScanPayload) Validate() (err error)

Validate validates the FileScanPayload type instance.

type Jobqueue

type Jobqueue struct {
	Jobqueue *Agentjobqueuedata `form:"jobqueue" json:"jobqueue" yaml:"jobqueue" xml:"jobqueue"`
}

Jobqueue media type (default view)

Identifier: application/vnd.jobqueue+json; view=default

func (*Jobqueue) Validate

func (mt *Jobqueue) Validate() (err error)

Validate validates the Jobqueue media type instance.

type Scan

type Scan struct {
	Scan *Scandata `form:"scan" json:"scan" yaml:"scan" xml:"scan"`
}

Scan media type (default view)

Identifier: application/vnd.scan+json; view=default

func (*Scan) Validate

func (mt *Scan) Validate() (err error)

Validate validates the Scan media type instance.

type ScanChecksPayload

type ScanChecksPayload struct {
	Checks []*CheckPayload `form:"checks" json:"checks" yaml:"checks" xml:"checks"`
}

ScanChecksPayload user type.

func (*ScanChecksPayload) Validate

func (ut *ScanChecksPayload) Validate() (err error)

Validate validates the ScanChecksPayload type instance.

type ScanData

type ScanData struct {
	// Number of checks of the scan
	Size int `form:"size" json:"size" yaml:"size" xml:"size"`
}

ScanData user type.

type ScanPayload

type ScanPayload struct {
	Scan *ScanChecksPayload `form:"scan,omitempty" json:"scan,omitempty" yaml:"scan,omitempty" xml:"scan,omitempty"`
}

ScanPayload user type.

func (*ScanPayload) Validate

func (ut *ScanPayload) Validate() (err error)

Validate validates the ScanPayload type instance.

type Scancheckdata

type Scancheckdata struct {
	// Name of the checktype this check is
	ChecktypeName string    `form:"checktype_name" json:"checktype_name" yaml:"checktype_name" xml:"checktype_name"`
	ID            uuid.UUID `form:"id" json:"id" yaml:"id" xml:"id"`
	Status        string    `form:"status" json:"status" yaml:"status" xml:"status"`
	// Target to be scanned. Can be a domain, hostname, IP or URL
	Target string `form:"target" json:"target" yaml:"target" xml:"target"`
}

Scancheckdata media type (default view)

Identifier: application/vnd.scancheckdata+json; view=default

func (*Scancheckdata) Validate

func (mt *Scancheckdata) Validate() (err error)

Validate validates the Scancheckdata media type instance.

type Scandata

type Scandata struct {
	ID uuid.UUID `form:"id" json:"id" yaml:"id" xml:"id"`
	// Number of checks of the scan
	Size int `form:"size" json:"size" yaml:"size" xml:"size"`
}

Scandata media type (default view)

Identifier: application/vnd.scandata+json; view=default

func (*Scandata) Validate

func (mt *Scandata) Validate() (err error)

Validate validates the Scandata media type instance.

type Scans

type Scans struct {
	Scans []*ScanData `form:"scans" json:"scans" yaml:"scans" xml:"scans"`
}

Scans media type (default view)

Identifier: application/vnd.scans+json; view=default

func (*Scans) Validate

func (mt *Scans) Validate() (err error)

Validate validates the Scans media type instance.

type Stat

type Stat struct {
	Status string `form:"status" json:"status" yaml:"status" xml:"status"`
	Total  int    `form:"total" json:"total" yaml:"total" xml:"total"`
}

Stat media type (default view)

Identifier: application/vnd.stat+json; view=default

func (*Stat) Validate

func (mt *Stat) Validate() (err error)

Validate validates the Stat media type instance.

type Stats

type Stats struct {
	Checks []*Stat `form:"checks" json:"checks" yaml:"checks" xml:"checks"`
}

Stats media type (default view)

Identifier: application/vnd.stats+json; view=default

func (*Stats) Validate

func (mt *Stats) Validate() (err error)

Validate validates the Stats media type instance.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL