Documentation
¶
Overview ¶
Package api provides primitives to interact with the openapi HTTP API.
Code generated by github.com/oapi-codegen/oapi-codegen/v2 version v2.4.1 DO NOT EDIT.
Package api provides primitives to interact with the openapi HTTP API.
Code generated by github.com/oapi-codegen/oapi-codegen/v2 version v2.4.1 DO NOT EDIT.
Package api provides primitives to interact with the openapi HTTP API.
Code generated by github.com/oapi-codegen/oapi-codegen/v2 version v2.4.1 DO NOT EDIT.
Index ¶
- Constants
- func GetSwagger() (swagger *openapi3.T, err error)
- func PathToRawSpec(pathToFile string) map[string]func() ([]byte, error)
- func RegisterHandlers(router gin.IRouter, si ServerInterface)
- func RegisterHandlersWithOptions(router gin.IRouter, si ServerInterface, options GinServerOptions)
- type APIError
- type AWSRegistry
- type AWSRegistryType
- type AccessTokenID
- type ApiKeyID
- type BuildID
- type BuildLogEntry
- type BuildStatusReason
- type CPUCount
- type CreatedAccessToken
- type CreatedTeamAPIKey
- type DiskMetrics
- type DiskSizeMB
- type EnvVars
- type EnvdVersion
- type Error
- type FromImageRegistry
- func (t FromImageRegistry) AsAWSRegistry() (AWSRegistry, error)
- func (t FromImageRegistry) AsGCPRegistry() (GCPRegistry, error)
- func (t FromImageRegistry) AsGeneralRegistry() (GeneralRegistry, error)
- func (t FromImageRegistry) Discriminator() (string, error)
- func (t *FromImageRegistry) FromAWSRegistry(v AWSRegistry) error
- func (t *FromImageRegistry) FromGCPRegistry(v GCPRegistry) error
- func (t *FromImageRegistry) FromGeneralRegistry(v GeneralRegistry) error
- func (t FromImageRegistry) MarshalJSON() ([]byte, error)
- func (t *FromImageRegistry) MergeAWSRegistry(v AWSRegistry) error
- func (t *FromImageRegistry) MergeGCPRegistry(v GCPRegistry) error
- func (t *FromImageRegistry) MergeGeneralRegistry(v GeneralRegistry) error
- func (t *FromImageRegistry) UnmarshalJSON(b []byte) error
- func (t FromImageRegistry) ValueByDiscriminator() (interface{}, error)
- type GCPRegistry
- type GCPRegistryType
- type GeneralRegistry
- type GeneralRegistryType
- type GetNodesNodeIDParams
- type GetSandboxesMetricsParams
- type GetSandboxesParams
- type GetSandboxesSandboxIDLogsParams
- type GetSandboxesSandboxIDMetricsParams
- type GetTeamsTeamIDMetricsMaxParams
- type GetTeamsTeamIDMetricsMaxParamsMetric
- type GetTeamsTeamIDMetricsParams
- type GetTemplatesParams
- type GetTemplatesTemplateIDBuildsBuildIDStatusParams
- type GetV2SandboxesParams
- type GinServerOptions
- type IdentifierMaskingDetails
- type ListedSandbox
- type LogLevel
- type MaxTeamMetric
- type MemoryMB
- type MiddlewareFunc
- type N400
- type N401
- type N403
- type N404
- type N409
- type N500
- type NewAccessToken
- type NewSandbox
- type NewTeamAPIKey
- type Node
- type NodeDetail
- type NodeID
- type NodeMetrics
- type NodeStatus
- type NodeStatusChange
- type PatchApiKeysApiKeyIDJSONRequestBody
- type PatchTemplatesTemplateIDJSONRequestBody
- type PostAccessTokensJSONRequestBody
- type PostApiKeysJSONRequestBody
- type PostNodesNodeIDJSONRequestBody
- type PostSandboxesJSONRequestBody
- type PostSandboxesSandboxIDRefreshesJSONBody
- type PostSandboxesSandboxIDRefreshesJSONRequestBody
- type PostSandboxesSandboxIDResumeJSONRequestBody
- type PostSandboxesSandboxIDTimeoutJSONBody
- type PostSandboxesSandboxIDTimeoutJSONRequestBody
- type PostTemplatesJSONRequestBody
- type PostTemplatesTemplateIDJSONRequestBody
- type PostV2TemplatesJSONRequestBody
- type PostV2TemplatesTemplateIDBuildsBuildIDJSONRequestBody
- type ResumedSandbox
- type Sandbox
- type SandboxDetail
- type SandboxID
- type SandboxLog
- type SandboxLogEntry
- type SandboxLogs
- type SandboxMetadata
- type SandboxMetric
- type SandboxState
- type SandboxesWithMetrics
- type ServerInterface
- type ServerInterfaceWrapper
- func (siw *ServerInterfaceWrapper) DeleteAccessTokensAccessTokenID(c *gin.Context)
- func (siw *ServerInterfaceWrapper) DeleteApiKeysApiKeyID(c *gin.Context)
- func (siw *ServerInterfaceWrapper) DeleteSandboxesSandboxID(c *gin.Context)
- func (siw *ServerInterfaceWrapper) DeleteTemplatesTemplateID(c *gin.Context)
- func (siw *ServerInterfaceWrapper) GetApiKeys(c *gin.Context)
- func (siw *ServerInterfaceWrapper) GetHealth(c *gin.Context)
- func (siw *ServerInterfaceWrapper) GetNodes(c *gin.Context)
- func (siw *ServerInterfaceWrapper) GetNodesNodeID(c *gin.Context)
- func (siw *ServerInterfaceWrapper) GetSandboxes(c *gin.Context)
- func (siw *ServerInterfaceWrapper) GetSandboxesMetrics(c *gin.Context)
- func (siw *ServerInterfaceWrapper) GetSandboxesSandboxID(c *gin.Context)
- func (siw *ServerInterfaceWrapper) GetSandboxesSandboxIDLogs(c *gin.Context)
- func (siw *ServerInterfaceWrapper) GetSandboxesSandboxIDMetrics(c *gin.Context)
- func (siw *ServerInterfaceWrapper) GetTeams(c *gin.Context)
- func (siw *ServerInterfaceWrapper) GetTeamsTeamIDMetrics(c *gin.Context)
- func (siw *ServerInterfaceWrapper) GetTeamsTeamIDMetricsMax(c *gin.Context)
- func (siw *ServerInterfaceWrapper) GetTemplates(c *gin.Context)
- func (siw *ServerInterfaceWrapper) GetTemplatesTemplateIDBuildsBuildIDStatus(c *gin.Context)
- func (siw *ServerInterfaceWrapper) GetTemplatesTemplateIDFilesHash(c *gin.Context)
- func (siw *ServerInterfaceWrapper) GetV2Sandboxes(c *gin.Context)
- func (siw *ServerInterfaceWrapper) PatchApiKeysApiKeyID(c *gin.Context)
- func (siw *ServerInterfaceWrapper) PatchTemplatesTemplateID(c *gin.Context)
- func (siw *ServerInterfaceWrapper) PostAccessTokens(c *gin.Context)
- func (siw *ServerInterfaceWrapper) PostApiKeys(c *gin.Context)
- func (siw *ServerInterfaceWrapper) PostNodesNodeID(c *gin.Context)
- func (siw *ServerInterfaceWrapper) PostSandboxes(c *gin.Context)
- func (siw *ServerInterfaceWrapper) PostSandboxesSandboxIDPause(c *gin.Context)
- func (siw *ServerInterfaceWrapper) PostSandboxesSandboxIDRefreshes(c *gin.Context)
- func (siw *ServerInterfaceWrapper) PostSandboxesSandboxIDResume(c *gin.Context)
- func (siw *ServerInterfaceWrapper) PostSandboxesSandboxIDTimeout(c *gin.Context)
- func (siw *ServerInterfaceWrapper) PostTemplates(c *gin.Context)
- func (siw *ServerInterfaceWrapper) PostTemplatesTemplateID(c *gin.Context)
- func (siw *ServerInterfaceWrapper) PostTemplatesTemplateIDBuildsBuildID(c *gin.Context)
- func (siw *ServerInterfaceWrapper) PostV2Templates(c *gin.Context)
- func (siw *ServerInterfaceWrapper) PostV2TemplatesTemplateIDBuildsBuildID(c *gin.Context)
- type Team
- type TeamAPIKey
- type TeamID
- type TeamMetric
- type TeamUser
- type Template
- type TemplateBuild
- type TemplateBuildFileUpload
- type TemplateBuildRequest
- type TemplateBuildRequestV2
- type TemplateBuildStartV2
- type TemplateBuildStatus
- type TemplateID
- type TemplateStep
- type TemplateUpdateRequest
- type UpdateTeamAPIKey
Constants ¶
const ( AccessTokenAuthScopes = "AccessTokenAuth.Scopes" AdminTokenAuthScopes = "AdminTokenAuth.Scopes" ApiKeyAuthScopes = "ApiKeyAuth.Scopes" Supabase1TokenAuthScopes = "Supabase1TokenAuth.Scopes" Supabase2TeamAuthScopes = "Supabase2TeamAuth.Scopes" )
Variables ¶
This section is empty.
Functions ¶
func GetSwagger ¶
GetSwagger returns the Swagger specification corresponding to the generated code in this file. The external references of Swagger specification are resolved. The logic of resolving external references is tightly connected to "import-mapping" feature. Externally referenced files must be embedded in the corresponding golang packages. Urls can be supported but this task was out of the scope.
func PathToRawSpec ¶
Constructs a synthetic filesystem for resolving external references when loading openapi specifications.
func RegisterHandlers ¶
func RegisterHandlers(router gin.IRouter, si ServerInterface)
RegisterHandlers creates http.Handler with routing matching OpenAPI spec.
func RegisterHandlersWithOptions ¶
func RegisterHandlersWithOptions(router gin.IRouter, si ServerInterface, options GinServerOptions)
RegisterHandlersWithOptions creates http.Handler with additional options
Types ¶
type AWSRegistry ¶
type AWSRegistry struct { // AwsAccessKeyId AWS Access Key ID for ECR authentication AwsAccessKeyId string `json:"awsAccessKeyId"` // AwsRegion AWS Region where the ECR registry is located AwsRegion string `json:"awsRegion"` // AwsSecretAccessKey AWS Secret Access Key for ECR authentication AwsSecretAccessKey string `json:"awsSecretAccessKey"` // Type Type of registry authentication Type AWSRegistryType `json:"type"` }
AWSRegistry defines model for AWSRegistry.
type AWSRegistryType ¶
type AWSRegistryType string
AWSRegistryType Type of registry authentication
const (
Aws AWSRegistryType = "aws"
)
Defines values for AWSRegistryType.
type BuildLogEntry ¶
type BuildLogEntry struct { // Level State of the sandbox Level LogLevel `json:"level"` // Message Log message content Message string `json:"message"` // Step Step in the build process related to the log entry Step *string `json:"step,omitempty"` // Timestamp Timestamp of the log entry Timestamp time.Time `json:"timestamp"` }
BuildLogEntry defines model for BuildLogEntry.
type BuildStatusReason ¶
type BuildStatusReason struct { // LogEntries Log entries related to the status reason LogEntries *[]BuildLogEntry `json:"logEntries,omitempty"` // Message Message with the status reason, currently reporting only for error status Message string `json:"message"` // Step Step that failed Step *string `json:"step,omitempty"` }
BuildStatusReason defines model for BuildStatusReason.
type CreatedAccessToken ¶
type CreatedAccessToken struct { // CreatedAt Timestamp of access token creation CreatedAt time.Time `json:"createdAt"` // Id Identifier of the access token Id openapi_types.UUID `json:"id"` Mask IdentifierMaskingDetails `json:"mask"` // Name Name of the access token Name string `json:"name"` // Token The fully created access token Token string `json:"token"` }
CreatedAccessToken defines model for CreatedAccessToken.
type CreatedTeamAPIKey ¶
type CreatedTeamAPIKey struct { // CreatedAt Timestamp of API key creation CreatedAt time.Time `json:"createdAt"` CreatedBy *TeamUser `json:"createdBy"` // Id Identifier of the API key Id openapi_types.UUID `json:"id"` // Key Raw value of the API key Key string `json:"key"` // LastUsed Last time this API key was used LastUsed *time.Time `json:"lastUsed"` Mask IdentifierMaskingDetails `json:"mask"` // Name Name of the API key Name string `json:"name"` }
CreatedTeamAPIKey defines model for CreatedTeamAPIKey.
type DiskMetrics ¶
type DiskMetrics struct { // Device Device name Device string `json:"device"` // FilesystemType Filesystem type (e.g., ext4, xfs) FilesystemType string `json:"filesystemType"` // MountPoint Mount point of the disk MountPoint string `json:"mountPoint"` // TotalBytes Total space in bytes TotalBytes uint64 `json:"totalBytes"` // UsedBytes Used space in bytes UsedBytes uint64 `json:"usedBytes"` }
DiskMetrics defines model for DiskMetrics.
type Error ¶
type Error struct { // Code Error code Code int32 `json:"code"` // Message Error Message string `json:"message"` }
Error defines model for Error.
type FromImageRegistry ¶
type FromImageRegistry struct {
// contains filtered or unexported fields
}
FromImageRegistry defines model for FromImageRegistry.
func (FromImageRegistry) AsAWSRegistry ¶
func (t FromImageRegistry) AsAWSRegistry() (AWSRegistry, error)
AsAWSRegistry returns the union data inside the FromImageRegistry as a AWSRegistry
func (FromImageRegistry) AsGCPRegistry ¶
func (t FromImageRegistry) AsGCPRegistry() (GCPRegistry, error)
AsGCPRegistry returns the union data inside the FromImageRegistry as a GCPRegistry
func (FromImageRegistry) AsGeneralRegistry ¶
func (t FromImageRegistry) AsGeneralRegistry() (GeneralRegistry, error)
AsGeneralRegistry returns the union data inside the FromImageRegistry as a GeneralRegistry
func (FromImageRegistry) Discriminator ¶
func (t FromImageRegistry) Discriminator() (string, error)
func (*FromImageRegistry) FromAWSRegistry ¶
func (t *FromImageRegistry) FromAWSRegistry(v AWSRegistry) error
FromAWSRegistry overwrites any union data inside the FromImageRegistry as the provided AWSRegistry
func (*FromImageRegistry) FromGCPRegistry ¶
func (t *FromImageRegistry) FromGCPRegistry(v GCPRegistry) error
FromGCPRegistry overwrites any union data inside the FromImageRegistry as the provided GCPRegistry
func (*FromImageRegistry) FromGeneralRegistry ¶
func (t *FromImageRegistry) FromGeneralRegistry(v GeneralRegistry) error
FromGeneralRegistry overwrites any union data inside the FromImageRegistry as the provided GeneralRegistry
func (FromImageRegistry) MarshalJSON ¶
func (t FromImageRegistry) MarshalJSON() ([]byte, error)
func (*FromImageRegistry) MergeAWSRegistry ¶
func (t *FromImageRegistry) MergeAWSRegistry(v AWSRegistry) error
MergeAWSRegistry performs a merge with any union data inside the FromImageRegistry, using the provided AWSRegistry
func (*FromImageRegistry) MergeGCPRegistry ¶
func (t *FromImageRegistry) MergeGCPRegistry(v GCPRegistry) error
MergeGCPRegistry performs a merge with any union data inside the FromImageRegistry, using the provided GCPRegistry
func (*FromImageRegistry) MergeGeneralRegistry ¶
func (t *FromImageRegistry) MergeGeneralRegistry(v GeneralRegistry) error
MergeGeneralRegistry performs a merge with any union data inside the FromImageRegistry, using the provided GeneralRegistry
func (*FromImageRegistry) UnmarshalJSON ¶
func (t *FromImageRegistry) UnmarshalJSON(b []byte) error
func (FromImageRegistry) ValueByDiscriminator ¶
func (t FromImageRegistry) ValueByDiscriminator() (interface{}, error)
type GCPRegistry ¶
type GCPRegistry struct { // ServiceAccountJson Service Account JSON for GCP authentication ServiceAccountJson string `json:"serviceAccountJson"` // Type Type of registry authentication Type GCPRegistryType `json:"type"` }
GCPRegistry defines model for GCPRegistry.
type GCPRegistryType ¶
type GCPRegistryType string
GCPRegistryType Type of registry authentication
const (
Gcp GCPRegistryType = "gcp"
)
Defines values for GCPRegistryType.
type GeneralRegistry ¶
type GeneralRegistry struct { // Password Password to use for the registry Password string `json:"password"` // Type Type of registry authentication Type GeneralRegistryType `json:"type"` // Username Username to use for the registry Username string `json:"username"` }
GeneralRegistry defines model for GeneralRegistry.
type GeneralRegistryType ¶
type GeneralRegistryType string
GeneralRegistryType Type of registry authentication
const (
Registry GeneralRegistryType = "registry"
)
Defines values for GeneralRegistryType.
type GetNodesNodeIDParams ¶
type GetNodesNodeIDParams struct { // ClusterID Identifier of the cluster ClusterID *openapi_types.UUID `form:"clusterID,omitempty" json:"clusterID,omitempty"` }
GetNodesNodeIDParams defines parameters for GetNodesNodeID.
type GetSandboxesMetricsParams ¶
type GetSandboxesMetricsParams struct { // SandboxIds Comma-separated list of sandbox IDs to get metrics for SandboxIds []string `form:"sandbox_ids" json:"sandbox_ids"` }
GetSandboxesMetricsParams defines parameters for GetSandboxesMetrics.
type GetSandboxesParams ¶
type GetSandboxesParams struct { // Metadata Metadata query used to filter the sandboxes (e.g. "user=abc&app=prod"). Each key and values must be URL encoded. Metadata *string `form:"metadata,omitempty" json:"metadata,omitempty"` }
GetSandboxesParams defines parameters for GetSandboxes.
type GetSandboxesSandboxIDLogsParams ¶
type GetSandboxesSandboxIDLogsParams struct { // Start Starting timestamp of the logs that should be returned in milliseconds Start *int64 `form:"start,omitempty" json:"start,omitempty"` // Limit Maximum number of logs that should be returned Limit *int32 `form:"limit,omitempty" json:"limit,omitempty"` }
GetSandboxesSandboxIDLogsParams defines parameters for GetSandboxesSandboxIDLogs.
type GetSandboxesSandboxIDMetricsParams ¶
type GetSandboxesSandboxIDMetricsParams struct { // Start Unix timestamp for the start of the interval, in seconds, for which the metrics Start *int64 `form:"start,omitempty" json:"start,omitempty"` End *int64 `form:"end,omitempty" json:"end,omitempty"` }
GetSandboxesSandboxIDMetricsParams defines parameters for GetSandboxesSandboxIDMetrics.
type GetTeamsTeamIDMetricsMaxParams ¶
type GetTeamsTeamIDMetricsMaxParams struct { // Start Unix timestamp for the start of the interval, in seconds, for which the metrics Start *int64 `form:"start,omitempty" json:"start,omitempty"` End *int64 `form:"end,omitempty" json:"end,omitempty"` // Metric Metric to retrieve the maximum value for Metric GetTeamsTeamIDMetricsMaxParamsMetric `form:"metric" json:"metric"` }
GetTeamsTeamIDMetricsMaxParams defines parameters for GetTeamsTeamIDMetricsMax.
type GetTeamsTeamIDMetricsMaxParamsMetric ¶
type GetTeamsTeamIDMetricsMaxParamsMetric string
GetTeamsTeamIDMetricsMaxParamsMetric defines parameters for GetTeamsTeamIDMetricsMax.
const ( ConcurrentSandboxes GetTeamsTeamIDMetricsMaxParamsMetric = "concurrent_sandboxes" SandboxStartRate GetTeamsTeamIDMetricsMaxParamsMetric = "sandbox_start_rate" )
Defines values for GetTeamsTeamIDMetricsMaxParamsMetric.
type GetTeamsTeamIDMetricsParams ¶
type GetTeamsTeamIDMetricsParams struct { // Start Unix timestamp for the start of the interval, in seconds, for which the metrics Start *int64 `form:"start,omitempty" json:"start,omitempty"` End *int64 `form:"end,omitempty" json:"end,omitempty"` }
GetTeamsTeamIDMetricsParams defines parameters for GetTeamsTeamIDMetrics.
type GetTemplatesParams ¶
type GetTemplatesParams struct {
TeamID *string `form:"teamID,omitempty" json:"teamID,omitempty"`
}
GetTemplatesParams defines parameters for GetTemplates.
type GetTemplatesTemplateIDBuildsBuildIDStatusParams ¶
type GetTemplatesTemplateIDBuildsBuildIDStatusParams struct { // LogsOffset Index of the starting build log that should be returned with the template LogsOffset *int32 `form:"logsOffset,omitempty" json:"logsOffset,omitempty"` Level *LogLevel `form:"level,omitempty" json:"level,omitempty"` }
GetTemplatesTemplateIDBuildsBuildIDStatusParams defines parameters for GetTemplatesTemplateIDBuildsBuildIDStatus.
type GetV2SandboxesParams ¶
type GetV2SandboxesParams struct { // Metadata Metadata query used to filter the sandboxes (e.g. "user=abc&app=prod"). Each key and values must be URL encoded. Metadata *string `form:"metadata,omitempty" json:"metadata,omitempty"` // State Filter sandboxes by one or more states State *[]SandboxState `form:"state,omitempty" json:"state,omitempty"` // NextToken Cursor to start the list from NextToken *string `form:"nextToken,omitempty" json:"nextToken,omitempty"` // Limit Maximum number of items to return per page Limit *int32 `form:"limit,omitempty" json:"limit,omitempty"` }
GetV2SandboxesParams defines parameters for GetV2Sandboxes.
type GinServerOptions ¶
type GinServerOptions struct { BaseURL string Middlewares []MiddlewareFunc ErrorHandler func(*gin.Context, error, int) }
GinServerOptions provides options for the Gin server.
type IdentifierMaskingDetails ¶
type IdentifierMaskingDetails struct { // MaskedValuePrefix Prefix used in masked version of the token or key MaskedValuePrefix string `json:"maskedValuePrefix"` // MaskedValueSuffix Suffix used in masked version of the token or key MaskedValueSuffix string `json:"maskedValueSuffix"` // Prefix Prefix that identifies the token or key type Prefix string `json:"prefix"` // ValueLength Length of the token or key ValueLength int `json:"valueLength"` }
IdentifierMaskingDetails defines model for IdentifierMaskingDetails.
type ListedSandbox ¶
type ListedSandbox struct { // Alias Alias of the template Alias *string `json:"alias,omitempty"` // ClientID Identifier of the client // Deprecated: ClientID string `json:"clientID"` // CpuCount CPU cores for the sandbox CpuCount CPUCount `json:"cpuCount"` // DiskSizeMB Disk size for the sandbox in MiB DiskSizeMB DiskSizeMB `json:"diskSizeMB"` // EndAt Time when the sandbox will expire EndAt time.Time `json:"endAt"` // EnvdVersion Version of the envd running in the sandbox EnvdVersion EnvdVersion `json:"envdVersion"` // MemoryMB Memory for the sandbox in MiB MemoryMB MemoryMB `json:"memoryMB"` Metadata *SandboxMetadata `json:"metadata,omitempty"` // SandboxID Identifier of the sandbox SandboxID string `json:"sandboxID"` // StartedAt Time when the sandbox was started StartedAt time.Time `json:"startedAt"` // State State of the sandbox State SandboxState `json:"state"` // TemplateID Identifier of the template from which is the sandbox created TemplateID string `json:"templateID"` }
ListedSandbox defines model for ListedSandbox.
type MaxTeamMetric ¶
type MaxTeamMetric struct { // Timestamp Timestamp of the metric entry // Deprecated: Timestamp time.Time `json:"timestamp"` // TimestampUnix Timestamp of the metric entry in Unix time (seconds since epoch) TimestampUnix int64 `json:"timestampUnix"` // Value The maximum value of the requested metric in the given interval Value float32 `json:"value"` }
MaxTeamMetric Team metric with timestamp
type MiddlewareFunc ¶
type NewAccessToken ¶
type NewAccessToken struct { // Name Name of the access token Name string `json:"name"` }
NewAccessToken defines model for NewAccessToken.
type NewSandbox ¶
type NewSandbox struct { // AllowInternetAccess Allow sandbox to access the internet AllowInternetAccess *bool `json:"allow_internet_access,omitempty"` // AutoPause Automatically pauses the sandbox after the timeout AutoPause *bool `json:"autoPause,omitempty"` EnvVars *EnvVars `json:"envVars,omitempty"` Metadata *SandboxMetadata `json:"metadata,omitempty"` // Secure Secure all system communication with sandbox Secure *bool `json:"secure,omitempty"` // TemplateID Identifier of the required template TemplateID string `json:"templateID"` // Timeout Time to live for the sandbox in seconds. Timeout *int32 `json:"timeout,omitempty"` }
NewSandbox defines model for NewSandbox.
type NewTeamAPIKey ¶
type NewTeamAPIKey struct { // Name Name of the API key Name string `json:"name"` }
NewTeamAPIKey defines model for NewTeamAPIKey.
type Node ¶
type Node struct { // ClusterID Identifier of the cluster ClusterID string `json:"clusterID"` // Commit Commit of the orchestrator Commit string `json:"commit"` // CreateFails Number of sandbox create fails CreateFails uint64 `json:"createFails"` // CreateSuccesses Number of sandbox create successes CreateSuccesses uint64 `json:"createSuccesses"` // Id Identifier of the node Id string `json:"id"` // Metrics Node metrics Metrics NodeMetrics `json:"metrics"` // NodeID Identifier of the nomad node // Deprecated: NodeID string `json:"nodeID"` // SandboxCount Number of sandboxes running on the node SandboxCount uint32 `json:"sandboxCount"` // SandboxStartingCount Number of starting Sandboxes SandboxStartingCount int `json:"sandboxStartingCount"` // ServiceInstanceID Service instance identifier of the node ServiceInstanceID string `json:"serviceInstanceID"` // Status Status of the node Status NodeStatus `json:"status"` // Version Version of the orchestrator Version string `json:"version"` }
Node defines model for Node.
type NodeDetail ¶
type NodeDetail struct { // CachedBuilds List of cached builds id on the node CachedBuilds []string `json:"cachedBuilds"` // ClusterID Identifier of the cluster ClusterID string `json:"clusterID"` // Commit Commit of the orchestrator Commit string `json:"commit"` // CreateFails Number of sandbox create fails CreateFails uint64 `json:"createFails"` // CreateSuccesses Number of sandbox create successes CreateSuccesses uint64 `json:"createSuccesses"` // Id Identifier of the node Id string `json:"id"` // Metrics Node metrics Metrics NodeMetrics `json:"metrics"` // NodeID Identifier of the nomad node // Deprecated: NodeID string `json:"nodeID"` // Sandboxes List of sandboxes running on the node Sandboxes []ListedSandbox `json:"sandboxes"` // ServiceInstanceID Service instance identifier of the node ServiceInstanceID string `json:"serviceInstanceID"` // Status Status of the node Status NodeStatus `json:"status"` // Version Version of the orchestrator Version string `json:"version"` }
NodeDetail defines model for NodeDetail.
type NodeMetrics ¶
type NodeMetrics struct { // AllocatedCPU Number of allocated CPU cores AllocatedCPU uint32 `json:"allocatedCPU"` // AllocatedMemoryBytes Amount of allocated memory in bytes AllocatedMemoryBytes uint64 `json:"allocatedMemoryBytes"` // CpuCount Total number of CPU cores on the node CpuCount uint32 `json:"cpuCount"` // CpuPercent Node CPU usage percentage CpuPercent uint32 `json:"cpuPercent"` // Disks Detailed metrics for each disk/mount point Disks []DiskMetrics `json:"disks"` // MemoryTotalBytes Total node memory in bytes MemoryTotalBytes uint64 `json:"memoryTotalBytes"` // MemoryUsedBytes Node memory used in bytes MemoryUsedBytes uint64 `json:"memoryUsedBytes"` }
NodeMetrics Node metrics
type NodeStatus ¶
type NodeStatus string
NodeStatus Status of the node
const ( NodeStatusConnecting NodeStatus = "connecting" NodeStatusDraining NodeStatus = "draining" NodeStatusReady NodeStatus = "ready" NodeStatusUnhealthy NodeStatus = "unhealthy" )
Defines values for NodeStatus.
type NodeStatusChange ¶
type NodeStatusChange struct { // ClusterID Identifier of the cluster ClusterID *openapi_types.UUID `json:"clusterID,omitempty"` // Status Status of the node Status NodeStatus `json:"status"` }
NodeStatusChange defines model for NodeStatusChange.
type PatchApiKeysApiKeyIDJSONRequestBody ¶
type PatchApiKeysApiKeyIDJSONRequestBody = UpdateTeamAPIKey
PatchApiKeysApiKeyIDJSONRequestBody defines body for PatchApiKeysApiKeyID for application/json ContentType.
type PatchTemplatesTemplateIDJSONRequestBody ¶
type PatchTemplatesTemplateIDJSONRequestBody = TemplateUpdateRequest
PatchTemplatesTemplateIDJSONRequestBody defines body for PatchTemplatesTemplateID for application/json ContentType.
type PostAccessTokensJSONRequestBody ¶
type PostAccessTokensJSONRequestBody = NewAccessToken
PostAccessTokensJSONRequestBody defines body for PostAccessTokens for application/json ContentType.
type PostApiKeysJSONRequestBody ¶
type PostApiKeysJSONRequestBody = NewTeamAPIKey
PostApiKeysJSONRequestBody defines body for PostApiKeys for application/json ContentType.
type PostNodesNodeIDJSONRequestBody ¶
type PostNodesNodeIDJSONRequestBody = NodeStatusChange
PostNodesNodeIDJSONRequestBody defines body for PostNodesNodeID for application/json ContentType.
type PostSandboxesJSONRequestBody ¶
type PostSandboxesJSONRequestBody = NewSandbox
PostSandboxesJSONRequestBody defines body for PostSandboxes for application/json ContentType.
type PostSandboxesSandboxIDRefreshesJSONBody ¶
type PostSandboxesSandboxIDRefreshesJSONBody struct { // Duration Duration for which the sandbox should be kept alive in seconds Duration *int `json:"duration,omitempty"` }
PostSandboxesSandboxIDRefreshesJSONBody defines parameters for PostSandboxesSandboxIDRefreshes.
type PostSandboxesSandboxIDRefreshesJSONRequestBody ¶
type PostSandboxesSandboxIDRefreshesJSONRequestBody PostSandboxesSandboxIDRefreshesJSONBody
PostSandboxesSandboxIDRefreshesJSONRequestBody defines body for PostSandboxesSandboxIDRefreshes for application/json ContentType.
type PostSandboxesSandboxIDResumeJSONRequestBody ¶
type PostSandboxesSandboxIDResumeJSONRequestBody = ResumedSandbox
PostSandboxesSandboxIDResumeJSONRequestBody defines body for PostSandboxesSandboxIDResume for application/json ContentType.
type PostSandboxesSandboxIDTimeoutJSONBody ¶
type PostSandboxesSandboxIDTimeoutJSONBody struct { // Timeout Timeout in seconds from the current time after which the sandbox should expire Timeout int32 `json:"timeout"` }
PostSandboxesSandboxIDTimeoutJSONBody defines parameters for PostSandboxesSandboxIDTimeout.
type PostSandboxesSandboxIDTimeoutJSONRequestBody ¶
type PostSandboxesSandboxIDTimeoutJSONRequestBody PostSandboxesSandboxIDTimeoutJSONBody
PostSandboxesSandboxIDTimeoutJSONRequestBody defines body for PostSandboxesSandboxIDTimeout for application/json ContentType.
type PostTemplatesJSONRequestBody ¶
type PostTemplatesJSONRequestBody = TemplateBuildRequest
PostTemplatesJSONRequestBody defines body for PostTemplates for application/json ContentType.
type PostTemplatesTemplateIDJSONRequestBody ¶
type PostTemplatesTemplateIDJSONRequestBody = TemplateBuildRequest
PostTemplatesTemplateIDJSONRequestBody defines body for PostTemplatesTemplateID for application/json ContentType.
type PostV2TemplatesJSONRequestBody ¶
type PostV2TemplatesJSONRequestBody = TemplateBuildRequestV2
PostV2TemplatesJSONRequestBody defines body for PostV2Templates for application/json ContentType.
type PostV2TemplatesTemplateIDBuildsBuildIDJSONRequestBody ¶
type PostV2TemplatesTemplateIDBuildsBuildIDJSONRequestBody = TemplateBuildStartV2
PostV2TemplatesTemplateIDBuildsBuildIDJSONRequestBody defines body for PostV2TemplatesTemplateIDBuildsBuildID for application/json ContentType.
type ResumedSandbox ¶
type ResumedSandbox struct { // AutoPause Automatically pauses the sandbox after the timeout // Deprecated: AutoPause *bool `json:"autoPause,omitempty"` // Timeout Time to live for the sandbox in seconds. Timeout *int32 `json:"timeout,omitempty"` }
ResumedSandbox defines model for ResumedSandbox.
type Sandbox ¶
type Sandbox struct { // Alias Alias of the template Alias *string `json:"alias,omitempty"` // ClientID Identifier of the client // Deprecated: ClientID string `json:"clientID"` // Domain Base domain where the sandbox traffic is accessible Domain *string `json:"domain"` // EnvdAccessToken Access token used for envd communication EnvdAccessToken *string `json:"envdAccessToken,omitempty"` // EnvdVersion Version of the envd running in the sandbox EnvdVersion EnvdVersion `json:"envdVersion"` // SandboxID Identifier of the sandbox SandboxID string `json:"sandboxID"` // TemplateID Identifier of the template from which is the sandbox created TemplateID string `json:"templateID"` }
Sandbox defines model for Sandbox.
type SandboxDetail ¶
type SandboxDetail struct { // Alias Alias of the template Alias *string `json:"alias,omitempty"` // ClientID Identifier of the client // Deprecated: ClientID string `json:"clientID"` // CpuCount CPU cores for the sandbox CpuCount CPUCount `json:"cpuCount"` // DiskSizeMB Disk size for the sandbox in MiB DiskSizeMB DiskSizeMB `json:"diskSizeMB"` // Domain Base domain where the sandbox traffic is accessible Domain *string `json:"domain"` // EndAt Time when the sandbox will expire EndAt time.Time `json:"endAt"` // EnvdAccessToken Access token used for envd communication EnvdAccessToken *string `json:"envdAccessToken,omitempty"` // EnvdVersion Version of the envd running in the sandbox EnvdVersion EnvdVersion `json:"envdVersion"` // MemoryMB Memory for the sandbox in MiB MemoryMB MemoryMB `json:"memoryMB"` Metadata *SandboxMetadata `json:"metadata,omitempty"` // SandboxID Identifier of the sandbox SandboxID string `json:"sandboxID"` // StartedAt Time when the sandbox was started StartedAt time.Time `json:"startedAt"` // State State of the sandbox State SandboxState `json:"state"` // TemplateID Identifier of the template from which is the sandbox created TemplateID string `json:"templateID"` }
SandboxDetail defines model for SandboxDetail.
type SandboxLog ¶
type SandboxLog struct { // Line Log line content Line string `json:"line"` // Timestamp Timestamp of the log entry Timestamp time.Time `json:"timestamp"` }
SandboxLog Log entry with timestamp and line
type SandboxLogEntry ¶
type SandboxLogEntry struct { Fields map[string]string `json:"fields"` // Level State of the sandbox Level LogLevel `json:"level"` // Message Log message content Message string `json:"message"` // Timestamp Timestamp of the log entry Timestamp time.Time `json:"timestamp"` }
SandboxLogEntry defines model for SandboxLogEntry.
type SandboxLogs ¶
type SandboxLogs struct { // LogEntries Structured logs of the sandbox LogEntries []SandboxLogEntry `json:"logEntries"` // Logs Logs of the sandbox Logs []SandboxLog `json:"logs"` }
SandboxLogs defines model for SandboxLogs.
type SandboxMetadata ¶
SandboxMetadata defines model for SandboxMetadata.
type SandboxMetric ¶
type SandboxMetric struct { // CpuCount Number of CPU cores CpuCount int32 `json:"cpuCount"` // CpuUsedPct CPU usage percentage CpuUsedPct float32 `json:"cpuUsedPct"` // DiskTotal Total disk space in bytes DiskTotal int64 `json:"diskTotal"` // DiskUsed Disk used in bytes DiskUsed int64 `json:"diskUsed"` // MemTotal Total memory in bytes MemTotal int64 `json:"memTotal"` // MemUsed Memory used in bytes MemUsed int64 `json:"memUsed"` // Timestamp Timestamp of the metric entry // Deprecated: Timestamp time.Time `json:"timestamp"` // TimestampUnix Timestamp of the metric entry in Unix time (seconds since epoch) TimestampUnix int64 `json:"timestampUnix"` }
SandboxMetric Metric entry with timestamp and line
type SandboxState ¶
type SandboxState string
SandboxState State of the sandbox
const ( Paused SandboxState = "paused" Running SandboxState = "running" )
Defines values for SandboxState.
type SandboxesWithMetrics ¶
type SandboxesWithMetrics struct {
Sandboxes map[string]SandboxMetric `json:"sandboxes"`
}
SandboxesWithMetrics defines model for SandboxesWithMetrics.
type ServerInterface ¶
type ServerInterface interface { // (POST /access-tokens) PostAccessTokens(c *gin.Context) // (DELETE /access-tokens/{accessTokenID}) DeleteAccessTokensAccessTokenID(c *gin.Context, accessTokenID AccessTokenID) // (GET /api-keys) GetApiKeys(c *gin.Context) // (POST /api-keys) PostApiKeys(c *gin.Context) // (DELETE /api-keys/{apiKeyID}) DeleteApiKeysApiKeyID(c *gin.Context, apiKeyID ApiKeyID) // (PATCH /api-keys/{apiKeyID}) PatchApiKeysApiKeyID(c *gin.Context, apiKeyID ApiKeyID) // (GET /health) GetHealth(c *gin.Context) // (GET /nodes) GetNodes(c *gin.Context) // (GET /nodes/{nodeID}) GetNodesNodeID(c *gin.Context, nodeID NodeID, params GetNodesNodeIDParams) // (POST /nodes/{nodeID}) PostNodesNodeID(c *gin.Context, nodeID NodeID) // (GET /sandboxes) GetSandboxes(c *gin.Context, params GetSandboxesParams) // (POST /sandboxes) PostSandboxes(c *gin.Context) // (GET /sandboxes/metrics) GetSandboxesMetrics(c *gin.Context, params GetSandboxesMetricsParams) // (DELETE /sandboxes/{sandboxID}) DeleteSandboxesSandboxID(c *gin.Context, sandboxID SandboxID) // (GET /sandboxes/{sandboxID}) GetSandboxesSandboxID(c *gin.Context, sandboxID SandboxID) // (GET /sandboxes/{sandboxID}/logs) GetSandboxesSandboxIDLogs(c *gin.Context, sandboxID SandboxID, params GetSandboxesSandboxIDLogsParams) // (GET /sandboxes/{sandboxID}/metrics) GetSandboxesSandboxIDMetrics(c *gin.Context, sandboxID SandboxID, params GetSandboxesSandboxIDMetricsParams) // (POST /sandboxes/{sandboxID}/pause) PostSandboxesSandboxIDPause(c *gin.Context, sandboxID SandboxID) // (POST /sandboxes/{sandboxID}/refreshes) PostSandboxesSandboxIDRefreshes(c *gin.Context, sandboxID SandboxID) // (POST /sandboxes/{sandboxID}/resume) PostSandboxesSandboxIDResume(c *gin.Context, sandboxID SandboxID) // (POST /sandboxes/{sandboxID}/timeout) PostSandboxesSandboxIDTimeout(c *gin.Context, sandboxID SandboxID) // (GET /teams) GetTeams(c *gin.Context) // (GET /teams/{teamID}/metrics) GetTeamsTeamIDMetrics(c *gin.Context, teamID TeamID, params GetTeamsTeamIDMetricsParams) // (GET /teams/{teamID}/metrics/max) GetTeamsTeamIDMetricsMax(c *gin.Context, teamID TeamID, params GetTeamsTeamIDMetricsMaxParams) // (GET /templates) GetTemplates(c *gin.Context, params GetTemplatesParams) // (POST /templates) PostTemplates(c *gin.Context) // (DELETE /templates/{templateID}) DeleteTemplatesTemplateID(c *gin.Context, templateID TemplateID) // (PATCH /templates/{templateID}) PatchTemplatesTemplateID(c *gin.Context, templateID TemplateID) // (POST /templates/{templateID}) PostTemplatesTemplateID(c *gin.Context, templateID TemplateID) // (POST /templates/{templateID}/builds/{buildID}) PostTemplatesTemplateIDBuildsBuildID(c *gin.Context, templateID TemplateID, buildID BuildID) // (GET /templates/{templateID}/builds/{buildID}/status) GetTemplatesTemplateIDBuildsBuildIDStatus(c *gin.Context, templateID TemplateID, buildID BuildID, params GetTemplatesTemplateIDBuildsBuildIDStatusParams) // (GET /templates/{templateID}/files/{hash}) GetTemplatesTemplateIDFilesHash(c *gin.Context, templateID TemplateID, hash string) // (GET /v2/sandboxes) GetV2Sandboxes(c *gin.Context, params GetV2SandboxesParams) // (POST /v2/templates) PostV2Templates(c *gin.Context) // (POST /v2/templates/{templateID}/builds/{buildID}) PostV2TemplatesTemplateIDBuildsBuildID(c *gin.Context, templateID TemplateID, buildID BuildID) }
ServerInterface represents all server handlers.
type ServerInterfaceWrapper ¶
type ServerInterfaceWrapper struct { Handler ServerInterface HandlerMiddlewares []MiddlewareFunc ErrorHandler func(*gin.Context, error, int) }
ServerInterfaceWrapper converts contexts to parameters.
func (*ServerInterfaceWrapper) DeleteAccessTokensAccessTokenID ¶
func (siw *ServerInterfaceWrapper) DeleteAccessTokensAccessTokenID(c *gin.Context)
DeleteAccessTokensAccessTokenID operation middleware
func (*ServerInterfaceWrapper) DeleteApiKeysApiKeyID ¶
func (siw *ServerInterfaceWrapper) DeleteApiKeysApiKeyID(c *gin.Context)
DeleteApiKeysApiKeyID operation middleware
func (*ServerInterfaceWrapper) DeleteSandboxesSandboxID ¶
func (siw *ServerInterfaceWrapper) DeleteSandboxesSandboxID(c *gin.Context)
DeleteSandboxesSandboxID operation middleware
func (*ServerInterfaceWrapper) DeleteTemplatesTemplateID ¶
func (siw *ServerInterfaceWrapper) DeleteTemplatesTemplateID(c *gin.Context)
DeleteTemplatesTemplateID operation middleware
func (*ServerInterfaceWrapper) GetApiKeys ¶
func (siw *ServerInterfaceWrapper) GetApiKeys(c *gin.Context)
GetApiKeys operation middleware
func (*ServerInterfaceWrapper) GetHealth ¶
func (siw *ServerInterfaceWrapper) GetHealth(c *gin.Context)
GetHealth operation middleware
func (*ServerInterfaceWrapper) GetNodes ¶
func (siw *ServerInterfaceWrapper) GetNodes(c *gin.Context)
GetNodes operation middleware
func (*ServerInterfaceWrapper) GetNodesNodeID ¶
func (siw *ServerInterfaceWrapper) GetNodesNodeID(c *gin.Context)
GetNodesNodeID operation middleware
func (*ServerInterfaceWrapper) GetSandboxes ¶
func (siw *ServerInterfaceWrapper) GetSandboxes(c *gin.Context)
GetSandboxes operation middleware
func (*ServerInterfaceWrapper) GetSandboxesMetrics ¶
func (siw *ServerInterfaceWrapper) GetSandboxesMetrics(c *gin.Context)
GetSandboxesMetrics operation middleware
func (*ServerInterfaceWrapper) GetSandboxesSandboxID ¶
func (siw *ServerInterfaceWrapper) GetSandboxesSandboxID(c *gin.Context)
GetSandboxesSandboxID operation middleware
func (*ServerInterfaceWrapper) GetSandboxesSandboxIDLogs ¶
func (siw *ServerInterfaceWrapper) GetSandboxesSandboxIDLogs(c *gin.Context)
GetSandboxesSandboxIDLogs operation middleware
func (*ServerInterfaceWrapper) GetSandboxesSandboxIDMetrics ¶
func (siw *ServerInterfaceWrapper) GetSandboxesSandboxIDMetrics(c *gin.Context)
GetSandboxesSandboxIDMetrics operation middleware
func (*ServerInterfaceWrapper) GetTeams ¶
func (siw *ServerInterfaceWrapper) GetTeams(c *gin.Context)
GetTeams operation middleware
func (*ServerInterfaceWrapper) GetTeamsTeamIDMetrics ¶
func (siw *ServerInterfaceWrapper) GetTeamsTeamIDMetrics(c *gin.Context)
GetTeamsTeamIDMetrics operation middleware
func (*ServerInterfaceWrapper) GetTeamsTeamIDMetricsMax ¶
func (siw *ServerInterfaceWrapper) GetTeamsTeamIDMetricsMax(c *gin.Context)
GetTeamsTeamIDMetricsMax operation middleware
func (*ServerInterfaceWrapper) GetTemplates ¶
func (siw *ServerInterfaceWrapper) GetTemplates(c *gin.Context)
GetTemplates operation middleware
func (*ServerInterfaceWrapper) GetTemplatesTemplateIDBuildsBuildIDStatus ¶
func (siw *ServerInterfaceWrapper) GetTemplatesTemplateIDBuildsBuildIDStatus(c *gin.Context)
GetTemplatesTemplateIDBuildsBuildIDStatus operation middleware
func (*ServerInterfaceWrapper) GetTemplatesTemplateIDFilesHash ¶
func (siw *ServerInterfaceWrapper) GetTemplatesTemplateIDFilesHash(c *gin.Context)
GetTemplatesTemplateIDFilesHash operation middleware
func (*ServerInterfaceWrapper) GetV2Sandboxes ¶
func (siw *ServerInterfaceWrapper) GetV2Sandboxes(c *gin.Context)
GetV2Sandboxes operation middleware
func (*ServerInterfaceWrapper) PatchApiKeysApiKeyID ¶
func (siw *ServerInterfaceWrapper) PatchApiKeysApiKeyID(c *gin.Context)
PatchApiKeysApiKeyID operation middleware
func (*ServerInterfaceWrapper) PatchTemplatesTemplateID ¶
func (siw *ServerInterfaceWrapper) PatchTemplatesTemplateID(c *gin.Context)
PatchTemplatesTemplateID operation middleware
func (*ServerInterfaceWrapper) PostAccessTokens ¶
func (siw *ServerInterfaceWrapper) PostAccessTokens(c *gin.Context)
PostAccessTokens operation middleware
func (*ServerInterfaceWrapper) PostApiKeys ¶
func (siw *ServerInterfaceWrapper) PostApiKeys(c *gin.Context)
PostApiKeys operation middleware
func (*ServerInterfaceWrapper) PostNodesNodeID ¶
func (siw *ServerInterfaceWrapper) PostNodesNodeID(c *gin.Context)
PostNodesNodeID operation middleware
func (*ServerInterfaceWrapper) PostSandboxes ¶
func (siw *ServerInterfaceWrapper) PostSandboxes(c *gin.Context)
PostSandboxes operation middleware
func (*ServerInterfaceWrapper) PostSandboxesSandboxIDPause ¶
func (siw *ServerInterfaceWrapper) PostSandboxesSandboxIDPause(c *gin.Context)
PostSandboxesSandboxIDPause operation middleware
func (*ServerInterfaceWrapper) PostSandboxesSandboxIDRefreshes ¶
func (siw *ServerInterfaceWrapper) PostSandboxesSandboxIDRefreshes(c *gin.Context)
PostSandboxesSandboxIDRefreshes operation middleware
func (*ServerInterfaceWrapper) PostSandboxesSandboxIDResume ¶
func (siw *ServerInterfaceWrapper) PostSandboxesSandboxIDResume(c *gin.Context)
PostSandboxesSandboxIDResume operation middleware
func (*ServerInterfaceWrapper) PostSandboxesSandboxIDTimeout ¶
func (siw *ServerInterfaceWrapper) PostSandboxesSandboxIDTimeout(c *gin.Context)
PostSandboxesSandboxIDTimeout operation middleware
func (*ServerInterfaceWrapper) PostTemplates ¶
func (siw *ServerInterfaceWrapper) PostTemplates(c *gin.Context)
PostTemplates operation middleware
func (*ServerInterfaceWrapper) PostTemplatesTemplateID ¶
func (siw *ServerInterfaceWrapper) PostTemplatesTemplateID(c *gin.Context)
PostTemplatesTemplateID operation middleware
func (*ServerInterfaceWrapper) PostTemplatesTemplateIDBuildsBuildID ¶
func (siw *ServerInterfaceWrapper) PostTemplatesTemplateIDBuildsBuildID(c *gin.Context)
PostTemplatesTemplateIDBuildsBuildID operation middleware
func (*ServerInterfaceWrapper) PostV2Templates ¶
func (siw *ServerInterfaceWrapper) PostV2Templates(c *gin.Context)
PostV2Templates operation middleware
func (*ServerInterfaceWrapper) PostV2TemplatesTemplateIDBuildsBuildID ¶
func (siw *ServerInterfaceWrapper) PostV2TemplatesTemplateIDBuildsBuildID(c *gin.Context)
PostV2TemplatesTemplateIDBuildsBuildID operation middleware
type Team ¶
type Team struct { // ApiKey API key for the team ApiKey string `json:"apiKey"` // IsDefault Whether the team is the default team IsDefault bool `json:"isDefault"` // Name Name of the team Name string `json:"name"` // TeamID Identifier of the team TeamID string `json:"teamID"` }
Team defines model for Team.
type TeamAPIKey ¶
type TeamAPIKey struct { // CreatedAt Timestamp of API key creation CreatedAt time.Time `json:"createdAt"` CreatedBy *TeamUser `json:"createdBy"` // Id Identifier of the API key Id openapi_types.UUID `json:"id"` // LastUsed Last time this API key was used LastUsed *time.Time `json:"lastUsed"` Mask IdentifierMaskingDetails `json:"mask"` // Name Name of the API key Name string `json:"name"` }
TeamAPIKey defines model for TeamAPIKey.
type TeamMetric ¶
type TeamMetric struct { // ConcurrentSandboxes The number of concurrent sandboxes for the team ConcurrentSandboxes int32 `json:"concurrentSandboxes"` // SandboxStartRate Number of sandboxes started per second SandboxStartRate float32 `json:"sandboxStartRate"` // Timestamp Timestamp of the metric entry // Deprecated: Timestamp time.Time `json:"timestamp"` // TimestampUnix Timestamp of the metric entry in Unix time (seconds since epoch) TimestampUnix int64 `json:"timestampUnix"` }
TeamMetric Team metric with timestamp
type TeamUser ¶
type TeamUser struct { // Email Email of the user Email string `json:"email"` // Id Identifier of the user Id openapi_types.UUID `json:"id"` }
TeamUser defines model for TeamUser.
type Template ¶
type Template struct { // Aliases Aliases of the template Aliases []string `json:"aliases"` // BuildCount Number of times the template was built BuildCount int32 `json:"buildCount"` // BuildID Identifier of the last successful build for given template BuildID string `json:"buildID"` // CpuCount CPU cores for the sandbox CpuCount CPUCount `json:"cpuCount"` // CreatedAt Time when the template was created CreatedAt time.Time `json:"createdAt"` CreatedBy *TeamUser `json:"createdBy"` // DiskSizeMB Disk size for the sandbox in MiB DiskSizeMB DiskSizeMB `json:"diskSizeMB"` // EnvdVersion Version of the envd running in the sandbox EnvdVersion EnvdVersion `json:"envdVersion"` // LastSpawnedAt Time when the template was last used LastSpawnedAt *time.Time `json:"lastSpawnedAt"` // MemoryMB Memory for the sandbox in MiB MemoryMB MemoryMB `json:"memoryMB"` // Public Whether the template is public or only accessible by the team Public bool `json:"public"` // SpawnCount Number of times the template was used SpawnCount int64 `json:"spawnCount"` // TemplateID Identifier of the template TemplateID string `json:"templateID"` // UpdatedAt Time when the template was last updated UpdatedAt time.Time `json:"updatedAt"` }
Template defines model for Template.
type TemplateBuild ¶
type TemplateBuild struct { // BuildID Identifier of the build BuildID string `json:"buildID"` // LogEntries Build logs structured LogEntries []BuildLogEntry `json:"logEntries"` // Logs Build logs Logs []string `json:"logs"` Reason *BuildStatusReason `json:"reason,omitempty"` // Status Status of the template Status TemplateBuildStatus `json:"status"` // TemplateID Identifier of the template TemplateID string `json:"templateID"` }
TemplateBuild defines model for TemplateBuild.
type TemplateBuildFileUpload ¶
type TemplateBuildFileUpload struct { // Present Whether the file is already present in the cache Present bool `json:"present"` // Url Url where the file should be uploaded to Url *string `json:"url,omitempty"` }
TemplateBuildFileUpload defines model for TemplateBuildFileUpload.
type TemplateBuildRequest ¶
type TemplateBuildRequest struct { // Alias Alias of the template Alias *string `json:"alias,omitempty"` // CpuCount CPU cores for the sandbox CpuCount *CPUCount `json:"cpuCount,omitempty"` // Dockerfile Dockerfile for the template Dockerfile string `json:"dockerfile"` // MemoryMB Memory for the sandbox in MiB MemoryMB *MemoryMB `json:"memoryMB,omitempty"` // ReadyCmd Ready check command to execute in the template after the build ReadyCmd *string `json:"readyCmd,omitempty"` // StartCmd Start command to execute in the template after the build StartCmd *string `json:"startCmd,omitempty"` // TeamID Identifier of the team TeamID *string `json:"teamID,omitempty"` }
TemplateBuildRequest defines model for TemplateBuildRequest.
type TemplateBuildRequestV2 ¶
type TemplateBuildRequestV2 struct { // Alias Alias of the template Alias string `json:"alias"` // CpuCount CPU cores for the sandbox CpuCount *CPUCount `json:"cpuCount,omitempty"` // MemoryMB Memory for the sandbox in MiB MemoryMB *MemoryMB `json:"memoryMB,omitempty"` // TeamID Identifier of the team TeamID *string `json:"teamID,omitempty"` }
TemplateBuildRequestV2 defines model for TemplateBuildRequestV2.
type TemplateBuildStartV2 ¶
type TemplateBuildStartV2 struct { // Force Whether the whole build should be forced to run regardless of the cache Force *bool `json:"force,omitempty"` // FromImage Image to use as a base for the template build FromImage *string `json:"fromImage,omitempty"` FromImageRegistry *FromImageRegistry `json:"fromImageRegistry,omitempty"` // FromTemplate Template to use as a base for the template build FromTemplate *string `json:"fromTemplate,omitempty"` // ReadyCmd Ready check command to execute in the template after the build ReadyCmd *string `json:"readyCmd,omitempty"` // StartCmd Start command to execute in the template after the build StartCmd *string `json:"startCmd,omitempty"` // Steps List of steps to execute in the template build Steps *[]TemplateStep `json:"steps,omitempty"` }
TemplateBuildStartV2 defines model for TemplateBuildStartV2.
type TemplateBuildStatus ¶
type TemplateBuildStatus string
TemplateBuildStatus Status of the template
const ( TemplateBuildStatusBuilding TemplateBuildStatus = "building" TemplateBuildStatusError TemplateBuildStatus = "error" TemplateBuildStatusReady TemplateBuildStatus = "ready" TemplateBuildStatusWaiting TemplateBuildStatus = "waiting" )
Defines values for TemplateBuildStatus.
type TemplateStep ¶
type TemplateStep struct { // Args Arguments for the step Args *[]string `json:"args,omitempty"` // FilesHash Hash of the files used in the step FilesHash *string `json:"filesHash,omitempty"` // Force Whether the step should be forced to run regardless of the cache Force *bool `json:"force,omitempty"` // Type Type of the step Type string `json:"type"` }
TemplateStep Step in the template build process
type TemplateUpdateRequest ¶
type TemplateUpdateRequest struct { // Public Whether the template is public or only accessible by the team Public *bool `json:"public,omitempty"` }
TemplateUpdateRequest defines model for TemplateUpdateRequest.
type UpdateTeamAPIKey ¶
type UpdateTeamAPIKey struct { // Name New name for the API key Name string `json:"name"` }
UpdateTeamAPIKey defines model for UpdateTeamAPIKey.