Add workspace creation feature
This commit is contained in:
15
internal/api/types.go
Normal file
15
internal/api/types.go
Normal file
@@ -0,0 +1,15 @@
|
||||
package api
|
||||
|
||||
// CreateWorkspaceRequest defines the request body for creating a new workspace.
|
||||
type CreateWorkspaceRequest struct {
|
||||
Image string `json:"image"`
|
||||
Env map[string]string `json:"env"`
|
||||
ResourceLimits *ResourceLimits `json:"resourceLimits"`
|
||||
WorkspaceID string `json:"workspaceId"`
|
||||
}
|
||||
|
||||
// ResourceLimits defines the CPU and memory resource limits.
|
||||
type ResourceLimits struct {
|
||||
CPU string `json:"cpu"`
|
||||
Memory string `json:"memory"`
|
||||
}
|
||||
Reference in New Issue
Block a user